【发布时间】:2014-09-17 18:39:23
【问题描述】:
byte checksum;
byte[] toBuff = new byte[20];
toBuff = BitConverter.GetBytes(intNumBuffer);
Array.Reverse(mybyte);
checksum = ComputeChecksum(toBuff); //int to byte array
// At this point, the array is something like this
// toBuff[0] = 25
// toBuff[1] = 0
// toBuff[2] = 0
// toBuff[3] = 0
toBuff[4] = checksum; //HERE IS WHERE OUR OF BOUNDS OCCURS
我是新手,非常感谢任何帮助。
谢谢
【问题讨论】:
-
你想做什么?
标签: c# bytearray indexoutofboundsexception