How to get the length of a Named Pipe message?  
Author Message
Olcay





PostPosted: Visual C# General, How to get the length of a Named Pipe message? Top

Hi everyone,

how can I determine the length of a message in a named pipe I am using the CreateFile API function to get the Handle to the named pipe and pass it to the FileStream constructor - I can read/write messages and even do async operations. The windows service (named pipe server) writes large XMLs (message) into the pipe. Right now I am using myFileStream.ReadByte() to read sigle bytes - pretty slow.

Is there any way to get the length of the message in a named pipe

Thanks,
Olcay


Visual C#2