文件名称:byte
介绍说明--下载内容均来自于网络,请自行研究使用
在写C#TCP通信程序时,发送数据时,只能发送byte数组,处理起来比较麻烦不说,如果是和VC6.0等写的程序通信的话,很多的都是传送结构体,在VC6.0中可以很方便的把一个char[]数组转换为一个结构体,而在C#却不能直接把byte数组转换为结构体,要在C#中发送结构体,可以按以下方法实现:
-Writing C# TCP communication program, send data, send the byte array can only handle up and not say too much trouble, if and VC6.0 to write programs such as communication, a lot of the structure are transmitted, in VC6. 0 can easily put a char [] array into a structure, while in C# but not directly to the byte array is converted to structure, to send a C# structure can be achieved by the following methods:
-Writing C# TCP communication program, send data, send the byte array can only handle up and not say too much trouble, if and VC6.0 to write programs such as communication, a lot of the structure are transmitted, in VC6. 0 can easily put a char [] array into a structure, while in C# but not directly to the byte array is converted to structure, to send a C# structure can be achieved by the following methods:
(系统自动生成,下载前可以参看下载内容)
下载文件列表
byte.txt