none
Open a project using a command button from another project

    Întrebare

  • I have a number of independent visual basic applications. Now I want to develop a window that will have command buttons to open each of the applications. How do I write the code in these buttons?

    Funflex

    27 martie 2012 05:45

Răspunsuri

  • Hi Funflex,

    Welcome to the MSDN forum.

    You can open the VB application with the help of thread class: http://msdn.microsoft.com/en-us/library/system.threading.thread.aspx 

    Here is a sample about open the Cmd.exe in VB.net:

    Private Sub Button1_Click(sender As System.Object, e As System.EventArgs) Handles Button1.Click
            Dim proc As New Process
            'Change the path to the VB.Net exe file.
            proc.StartInfo.FileName = "C:\Windows\System32\cmd.exe"
            Try
                proc.Start()
            Catch ex As Exception
                MessageBox.Show(ex.Message)
            End Try
        End Sub

    You can try to change the file name of the VB file you want to open.

    Hope it helps. 


    Mark Liu-lxf [MSFT]
    MSDN Community Support | Feedback to us

    28 martie 2012 08:02
    Moderator

Toate mesajele

  • Hi Funflex,

    Welcome to the MSDN forum.

    You can open the VB application with the help of thread class: http://msdn.microsoft.com/en-us/library/system.threading.thread.aspx 

    Here is a sample about open the Cmd.exe in VB.net:

    Private Sub Button1_Click(sender As System.Object, e As System.EventArgs) Handles Button1.Click
            Dim proc As New Process
            'Change the path to the VB.Net exe file.
            proc.StartInfo.FileName = "C:\Windows\System32\cmd.exe"
            Try
                proc.Start()
            Catch ex As Exception
                MessageBox.Show(ex.Message)
            End Try
        End Sub

    You can try to change the file name of the VB file you want to open.

    Hope it helps. 


    Mark Liu-lxf [MSFT]
    MSDN Community Support | Feedback to us

    28 martie 2012 08:02
    Moderator
  • Hi Funflex,

    We haven’t heard from you for several days. I’d like to mark my reply as answer firstly. If you have any additional questions, you also can unmark the replay and post your question here. 

    Sorry for any inconvenience and have a nice day.


    Mark Liu-lxf [MSFT]
    MSDN Community Support | Feedback to us

    5 aprilie 2012 06:42
    Moderator