函数原型
BOOL TransactNamedPipe(
HANDLE hNamedPipe, // handle to named pipe
//打开的命名管道句柄,由创建服务器端的命名管道函数或客户端的打开命名管道函数返回
LPVOID lpInBuffer, // pointer to write buffer
DWORD nInBufferSize, // size of the write buffer, in bytes
//写缓冲区的开始地址与需要写入的数据量大小
LPVOID lpOutBuffer, // pointer to read buffer
DWORD nOutBufferSize, // size of read buffer, in bytes
//读缓冲区的开始地址与能够读入的数据量
LPDWORD lpBytesRead, // pointer to variable for bytes read
//实际读取的数据量
LPOVERLAPPED lpOverlapped // pointer to overlapped structure
//重叠操作结构
);