I think I encountered something extraordinary strange in VS 2008.
All the array values are 0x00
, but why it is displayed 0x00000008
at the start of the variable?
I think I encountered something extraordinary strange in VS 2008.
All the array values are 0x00
, but why it is displayed 0x00000008
at the start of the variable?
Visual studio is displaying the size of your array (in items) not the value. You have eight bytes in your array denoted by byte[8]
in decimal or byte[0x00000008]
as a 32-bit hex value.
Right click the window and select Hexadecimal Display
to switch to a decimal view of the values. I find the decimal view more workable when dealing with small integer types and you won't get confused by all the extra hex notation (although it depends on your personal preference).
This is the length of the array. Notice that in the first column it's listing the indices - there are eight items in the array. (You could think of it as saying that the value of the array is a bytearray with eight items).