I have a server and a client. Server sends an executable and an input.txt to the client. Client should execute it and send output to the server but I have a problem. When I try to run executable it gives an error about argument format. After that I save input file as (make just a quick char addition and removing) executable runs succesfully after saving it as a different file altough it has the exact content.
I'm saving the file using BinaryWriter :
FileStream fs = File.Open(filename, FileMode.OpenOrCreate);
BinaryWriter BW = new BinaryWriter(fs);
.......
fs.Close();
BW.Close();
I run executable with the parameter input.txt after closing the BinaryWriter and filestream.I think there is a problem with saving the file or maybe closing the stream but I couldnot find it yet. Any help would be appreciated...