Quote:
Originally Posted by Safsbro
I'm fairly new at Visual basics and have not really played much with C+ or C++ class Any how I made a launcher for a friend"s server, I am working with Microsoft Visual Studio 2010 Ultimate, Anyway the Launcher does what it is intended to do . Start the client and auto patch . the Forms declarations are as fallows:
Public Class Form1
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
Shell("soul.exe")
End Sub
Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
Shell("AutoPatch.exe")
End Sub
End Class
My problem is that it will not auto close the launcher when the client starts , Do i need to insert a finalize insert to have it exit when the client is initialized ? Can anyone help me out with this please? and thank you
|
This is the wrong section for this topic. But I will answer it anyways.
The ideal way to handle the starting of the exe files are different than the way you have done it, sure you can do it your way, but Its better
* doing it like the following.
Code:
Public Class Form1
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
'Starts the soul that is in the client folder.
[color=red]System.Diagnostics.Process.Start(Application.StartUpPath & "\soul.exe", "blacknull")[/color]
'Exits the Application
[color=blue]Application.Exit()[/color]
End Sub
Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
'Starts the Auto Patcher in the client folder
[color=red]System.Diagnostics.Process.Start(Application.StartUpPath & "\AutoPatch.exe")[/color]
'Exits the application
[color=blue]Application.Exit()[/color]
End Sub
End Class
The red text will load the exe files in a way that I find the best.
The blue actually does the closing of the loader.
* are my opinions on it.
Any other questions, You have my contact info, feel free to msg me, ill get back to you as soon as I can.