Ok, so lost me...
You are going to have to back up a step, and explain what you are trying to do.
Gary
Printable View
Ok, so lost me...
You are going to have to back up a step, and explain what you are trying to do.
Gary
Hey,
I think this is the code for launching .bat [the others have not worked :( ] , but im confused about 'paths' do i leave that ? , or does soemthing replace that. I have updated code with new file driectories.
Heres code :
Thanks for your help. :)Code:Dim psi As New ProcessStartInfo(paths.NFBuddyDir & "\Server" & ServerID + 1 & ".bat")
psi.WorkingDirectory = paths.NFBuddyDir
Process.Start(psi)
paths must be a variable that is declared elsewhere in your code.
Can you show where that is? You must be setting this variable up somewhere.
Gary
This is all of the code :)Code:Private Sub StartToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles StartToolStripMenuItem.Click
Dim psi As New ProcessStartInfo("Program Files (x86)\Nightfire Dedicated Server\Server1.bat")
psi.WorkingDirectory = Nightfire Dedicated Server\Server1.bat
Process.Start(psi)
End Sub
Ok, so now you are jumping onto a completely different piece of code.
I take it this is the version that you are currently using, correct? And I am guessing that it is giving you an error, correct?
As per the documentation:
http://msdn.microsoft.com/en-us/libr...directory.aspx
Expects a string. You are not giving it a string. And a string to a file, which isn't correct.
Gary
Also, you are using the constructor completely wrong!!
Have you read the documentation?
http://msdn.microsoft.com/en-us/library/27xafxda.aspx
Gary
Hi i read that this or soemthuing like this should work ill start reading.