02-06-2006 09:59 AM
You don't have to use string operations (which terminate on a 0x00) with ComWrt(); it accepts an array of bytes as a buffer. This is why you need to pass the count in to the function as well; something which is not normally needed with ASCIIZ functions. ComWrt() will happily transmit a buffer full of 0x00s, if you want it to.
JR
02-06-2006 10:32 AM
Aha! I got it! Kumar, in String display (the one shown by Shift+F7) simply go to Options menu and select "Display Entire Buffer": you'll see the whole content of the string even after the first NUL byte (in your example you'll see "AB" then a small box for the NUL character then "D" then a second black box). And if you select Format >> Decimal (or Hex or as you prefer) you can verify that all bytes you have set into the string are there exactly as you prepared them!
The reason of this particular behaviour is that "normal" string display acts as all string operations, that terminates on first NUL bytes as JR told you. In "Entire buffer" mode, though, the window displays all actual content of the whole string.