[Solved] Receiving an “Error: expected an identifier” on C++ for “==”

if (f_in); std::ifstream == int NULL); You could rewrite this as this: if (f_in) ; std::ifstream == int NULL); And you can see that this doesn’t really make sense. Maybe you meant: if (!f_in) { fprintf(stderr, “Can’t open input file in.list!\n”); exit(1); } Or if (f_in == NULL) { fprintf(stderr, “Can’t open input file in.list!\n”); … Read more

[Solved] FileStream throws File not found

Ok, I found the problem: My server-side program interefered with my client-side program. Here’s the fixed code for the SendFile code of my client program: public void SendFile(String fileName, long fileSize, NetworkStream io) { SendFileNameToServer(); SendFileSizeToServer(); byte[] fileData; try { FileStream openFileStream = File.OpenRead(fileName); BinaryReader bReader = new BinaryReader(openFileStream); Int32 remainingSize = Convert.ToInt32(_fileSize); do { … Read more