Subscribe now and choose from over 30 free gifts worth up to £49 - Plus get £25 to spend in our shop
VS .Net 2003 to debug some C code.
In the watch window the values of my chars are being displayed as numbers only (ASCI in base10 I assume).
Is that a settting that will show me both the numerical ASCI value and the 'Alphabetical' character? ie 82 = 'R'
Hopefully I'm asking the question right as I kinda out of my depth here.
From memory you can right click and choose other display formats.
It should really show the ASCII characters for the char type , unless they are being stored as int or something, in which case you can type in a suitable cast into the Watch window.
you can add multiple watches, but you will need to run a conversion on the string value which VS.net doesn't really like doing. best way might be to add a line which converts the char to a string and add a watch on that variable - either stick it in an IF #DEBUG so it doesn;t compile in release mode, or better still remove it when you;re sure your code works as required
Right mouse click only gives me option for Hex display.
Normally it is pretty good at working our types. Are you being slack with typing?
try adding a watch with a cast, eg: (char) my_var
or use the memory window: type &my_var in the address box and you get a memory dump with binary and ASCII from that address onwards
Thanks for the replys.
Can do all the above for specific chars but Im debugging lots and lots of preexisting code so its not pratical. I remember in a prev version VS6.0 it would show me both.
