I have the following delegate method of NSURLConnection
- (void)connectionDidFinishLoading:(NSURLConnection *)connection
{
NSLog(@"DONE, Receive bytes: %d", [webData length]);
NSString *theXML = [[NSString alloc]initWithBytes:[webData mutableBytes] length:[webData length] encoding:NSUTF8StringEncoding];
//NSLog(theXML);
[theXML release];
if(xmlParser)
{
[xmlParser release];
}
else
{
xmlParser = [[NSXMLParser alloc]initWithData:webData];
[xmlParser setDelegate:self];
[xmlParser setShouldResolveExternalEntities:YES];
[xmlParser parse];
[connection release];
[webData release];
NSLog(@"\n\n\n\n");
NSLog(httpResult);
}
I want to return httpResult
- how do i do this? I have the above method in a class. I create an instance of this class in another controller class which calls a function to create an http request. This function then in turn calls this delegate method. How do i return httpResult
to the controller class?
I have figured it out - thanks guys