IIS and VB6

Discussion in 'ASP General' started by Giles, Jan 12, 2008.

  1. Giles

    Giles Guest

    Is there a way for a VB6 program to access IIS Manager without using
    sendkeys? Specifically,I want to be able to:
    1. Change the Default Web Site Home Directory to a removable Memory Stick
    (e.g. f:\)
    2. Set write permission to 2 folders which contain access databases (e.g.
    f:\db\ and F:\db2\)
    This is so my web site can be demonstrated on (localhost) laptops that don't
    have an internet connection, without the (untrained) demonstrator having to
    access IIS manager - they just run the exe to set up the machine.
    Giles, Jan 12, 2008
    #1
    1. Advertising

  2. Giles

    Giles Guest

    "Giles" wrote
    > Is there a way for a VB6 program to access IIS Manager without using
    > sendkeys? Specifically,I want to be able to:
    > 1. Change the Default Web Site Home Directory to a removable Memory Stick
    > (e.g. f:\)
    > 2. Set write permission to 2 folders which contain access databases (e.g.
    > f:\db\ and F:\db2\)
    > This is so my web site can be demonstrated on (localhost) laptops that
    > don't have an internet connection, without the (untrained) demonstrator
    > having to access IIS manager - they just run the exe to set up the
    > machine.

    Should have added: Windows XP, IIS 5.1
    Giles, Jan 12, 2008
    #2
    1. Advertising

  3. Giles wrote:
    > Is there a way for a VB6 program to access IIS Manager without using
    > sendkeys? Specifically,I want to be able to:
    > 1. Change the Default Web Site Home Directory to a removable Memory
    > Stick (e.g. f:\)
    > 2. Set write permission to 2 folders which contain access databases
    > (e.g. f:\db\ and F:\db2\)
    > This is so my web site can be demonstrated on (localhost) laptops
    > that don't have an internet connection, without the (untrained)
    > demonstrator having to access IIS manager - they just run the exe to
    > set up the machine.


    I don't know. Possibly by WMI ...
    You should post to a VB group, .vb.general.discussion, or to the
    inetserver.iis group (or both - if you do, please crosspost instead of
    multiposting).

    --
    Microsoft MVP - ASP/ASP.NET
    Please reply to the newsgroup. This email account is my spam trap so I
    don't check it very often. If you must reply off-line, then remove the
    "NO SPAM"
    Bob Barrows [MVP], Jan 12, 2008
    #3
  4. "Bob Barrows [MVP]" <> wrote in message
    news:...
    > Giles wrote:
    > > Is there a way for a VB6 program to access IIS Manager without using
    > > sendkeys? Specifically,I want to be able to:
    > > 1. Change the Default Web Site Home Directory to a removable Memory
    > > Stick (e.g. f:\)
    > > 2. Set write permission to 2 folders which contain access databases
    > > (e.g. f:\db\ and F:\db2\)
    > > This is so my web site can be demonstrated on (localhost) laptops
    > > that don't have an internet connection, without the (untrained)
    > > demonstrator having to access IIS manager - they just run the exe to
    > > set up the machine.

    >
    > I don't know. Possibly by WMI ...
    > You should post to a VB group, .vb.general.discussion, or to the
    > inetserver.iis group (or both - if you do, please crosspost instead of
    > multiposting).
    >



    Actually one of the best places to get this sort of help is the
    m.p.scripting.vbscript group. Present it as VBScript question, the port to
    VB6 will be a no brainer.

    Using ADSI this code will set the path for the root home directory for the
    Default Web Site.

    Dim moDir

    Set moDir = GetObject("IIS://localhost/w3svc/1/root")

    moDir.Path = "f:\"
    moDir.SetInfo

    It is based on the assumption that the default web site has the identity of
    1.

    However a the chaps in the VBScript group can probably give a complete WMI
    based answer.


    --
    Anthony Jones - MVP ASP/ASP.NET
    Anthony Jones, Jan 12, 2008
    #4
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Alfred Sehmueller

    Debugging ASP.NET and VB6 dll

    Alfred Sehmueller, Apr 7, 2004, in forum: ASP .Net
    Replies:
    0
    Views:
    570
    Alfred Sehmueller
    Apr 7, 2004
  2. William Gower

    VB6 and .net

    William Gower, Apr 29, 2004, in forum: ASP .Net
    Replies:
    1
    Views:
    407
    Ken Cox [Microsoft MVP]
    Apr 30, 2004
  3. William Gower

    vb6 and .net windows forms

    William Gower, Apr 29, 2004, in forum: ASP .Net
    Replies:
    0
    Views:
    289
    William Gower
    Apr 29, 2004
  4. Al

    VB6 Activex .DLL for IIS

    Al, Jun 2, 2005, in forum: ASP General
    Replies:
    4
    Views:
    539
    Tim Slattery
    Jun 3, 2005
  5. AlBruAn

    New install of VB6 doesn't recognize IIS

    AlBruAn, Dec 6, 2008, in forum: ASP General
    Replies:
    3
    Views:
    587
    Anthony Jones
    Dec 6, 2008
Loading...

Share This Page