Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- string textResponse;
- byte[] bytesResponse
- if (isRunning == true)
- {
- textResponse = "Running";
- bytesResponse = ASCIIEncoding.ASCII.GetBytes(textResponse);
- // Console.WriteLine("Sending back : " + isRunning);
- // nwStream.Write(bytesResponse, 0, bytesResponse.Length);
- // client.Close();
- // listener.Stop();
- }
- {
- //execute if exe is not running:
- textResponse = "Stoped";
- bytesResponse = ASCIIEncoding.ASCII.GetBytes(textResponse);
- // Console.WriteLine("Sending back : " + isRunning);
- // nwStream.Write(bytesResponse, 0, bytesResponse.Length);
- // client.Close();
- // listener.Stop();
- }
- Console.WriteLine("Sending back : " + isRunning);
- nwStream.Write(bytesResponse, 0, bytesResponse.Length);
- client.Close();
- listener.Stop();
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement