111,126
社区成员
发帖
与我相关
我的任务
分享
string a = "61-00-61-00";
string[] result = a.Split(new char[]{'-'});
byte[] arrByte = new byte[result.Length];
for(int i=0;i<result.Length;i++)
{
arrByte[i] = Convert.ToByte(result[i]);
}
string input = "61-00-61-00";
byte[] result = Array.ConvertAll<string, byte>(input.Split('-'), delegate(string s) { return byte.Parse(s); });
string test = "61-00-61-00";
byte[] result = System.Text.Encoding.Default.GetBytes(test);