Search code examples
iosgpswcf-rest

Error on creating NSString of url


I want to send my gps data from my iphone/ipad using restful service, but i am getting error

'NSInvalidArgumentException reason: unrecognized selector sent to class'

I am getting error on following code..

 [NSString stringwithFormat:@"http://192.168.0.105/TestServices/Service2.svc/gpsdata?latitude=%f&longitude=%f",location.coordinate.latitude,location.coordinate.longitude];

Solution

  • Capitalization is incorrect, it should be stringWithFormat!