字符串转成16进制数组
private static byte[] strToToHexByte(string hexString) //字符串转成16进制数组
{ 
hexString = hexString.Replace(" ", ""); 
if ((hexString.Length % 2) != 0) 
hexString += " "; 
byte[] returnBytes = new byte[hexString.Length / 2]; 
for (int i = 0; i < returnBytes.Length; i++) 
returnBytes[i] = Convert.ToByte(hexString.Substring(i * 2, 2), 16); 
return returnBytes; 
}
                    
                
                
            
        
浙公网安备 33010602011771号