Menu

#15 asString() on intValue throws exception

open-invalid
nobody
None
5
2010-06-26
2010-06-26
sorenriise
No

I had expected just about everything should be able to retrieve as String -- including objects and arrays (feature suggestion).

reader.parse("{\"intvalue\":1}",root);
if (root["intvalue"].isConvertibleTo(Json::stringValue)) // isConvertibleTo is returning true
cout << root["intvalue"].asString() // throws exception......

Discussion

  • sorenriise

    sorenriise - 2010-06-26

    Posted to wrong project

     
  • sorenriise

    sorenriise - 2010-06-26
    • status: open --> open-invalid
     

Log in to post a comment.