7

In my iPhone app, I am making an access to the webserver to fetch the data.

Here I am using JSON to retrieve the data from database.

I get a warning that says:

NSString may not respond to '-JSONValue'

How to resolve it?

halfer
  • 19,824
  • 17
  • 99
  • 186
Parth Bhatt
  • 19,381
  • 28
  • 133
  • 216
  • Worth having a look at [this page](http://code.google.com/p/json-framework/issues/detail?id=22) for additional tips. – Simon Whitaker Jan 12 '11 at 13:25
  • See my response in http://stackoverflow.com/questions/10379859/instance-method-jsonvaluenot-found-return-type-defaults-to-id/19300534#19300534 – BananaMan Oct 10 '13 at 15:53

3 Answers3

9

Add this #import "JSON.h" at the top of your .m or .h file.

Alex Terente
  • 12,006
  • 5
  • 51
  • 71
2

Have you tried to add JSON Library to your project and import it

#import "JSON/JSON.h"
ipraba
  • 16,485
  • 4
  • 59
  • 58
1

You probably just miss the include to your JSON library

VdesmedT
  • 9,037
  • 3
  • 34
  • 50