Calling Program A from Program B

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • fripper

    #1

    Calling Program A from Program B


    I want to write a sort of "program manager" (in VB 2005) from which users
    can select from a list of other programs I have written ... and then when
    the user exits that program have control come back to the program manager so
    the user can select another program to be executed. I do not know how to
    call one program from another ... or how to return to the calling program.
    I have looked through the "How to's" in VB 2005 Help but did not find this
    subject broached. Any thoughts would be appreciated.

    Thanks.



  • Chris

    #2
    Re: Calling Program A from Program B

    fripper wrote:[color=blue]
    > I want to write a sort of "program manager" (in VB 2005) from which users
    > can select from a list of other programs I have written ... and then when
    > the user exits that program have control come back to the program manager so
    > the user can select another program to be executed. I do not know how to
    > call one program from another ... or how to return to the calling program.
    > I have looked through the "How to's" in VB 2005 Help but did not find this
    > subject broached. Any thoughts would be appreciated.
    >
    > Thanks.
    >
    >
    >[/color]

    Look at the Process class. It will let you launch new programs. When
    your "child" process closes down have it launch the program manager again.

    chris

    Comment

    • Cor Ligthert [MVP]

      #3
      Re: Calling Program A from Program B

      Fripper,

      In addition to Chris a simple sample.

      \\\Notepad
      Dim p As New Process
      Dim pi As New ProcessStartInf o
      pi.arguments = "c:\windows\win .ini"
      pi.FileName = "notepad.ex e"
      p.startinfo = pi
      p.Start()
      ///

      I hope this helps,

      Cor


      Comment

      • Herfried K. Wagner [MVP]

        #4
        Re: Calling Program A from Program B

        "fripper" <young@indiana. edu> schrieb:[color=blue]
        > I want to write a sort of "program manager" (in VB 2005) from which users
        > can select from a list of other programs I have written ... and then when
        > the user exits that program have control come back to the program manager
        > so the user can select another program to be executed. I do not know how
        > to call one program from another ... or how to return to the calling
        > program.[/color]

        'System.Diagnos tics.Process'.

        --
        M S Herfried K. Wagner
        M V P <URL:http://dotnet.mvps.org/>
        V B <URL:http://classicvb.org/petition/>

        Comment

        Working...