I am having a problem converting a value to int.
I ran this query to count number of tags in xml file
var items = (from category in xml.Descendants("category")
where category.Attribute("id").Value != "0"
select category).Count();
it is returning me this 0x00000002 when i am expecting it to return 2. I tried converting it to int using Convert.ToInt32 and (int)variable methods but it stays at 0x00000002. Any help will be appreciated. Thanks.
errrrr, hex is not a data type, its just one of many ways of viewing ints.
in your debugger, deselect hex display
(right click the variable while debugging )