iphone - NSURLConnection doesn't call delegate methods -


i saw similar questions here, couldn't find solution problem. have simple nsurlconnection in main thread (at least didn't create other threads), delegate methods aren't called

[[[nsurlconnection alloc] initwithrequest:request delegate:self] autorelease]; 

and no methods called, e.g.

- (void)connection:(nsurlconnection *)connection didreceiveresponse:(nsurlresponse *)response { nslog(@"didreceiveresponse"); } 

self delegate nsxmlparser, think should not problem, have working in other class in same project. checked 10 times already, can't find problem.

i've seen hack solve here: http://www.depl0y.com/?p=345 don't it, may knows better solution? thanks

the reason know separate thread (that terminated when delegate methods called).

try nslog(@"is%@ main thread", ([nsthread ismainthread] ? @"" : @" not"));right before url connection creation


Comments

Popular posts from this blog

windows - Why does Vista not allow creation of shortcuts to "Programs" on a NonAdmin account? Not supposed to install apps from NonAdmin account? -

c++ - How do I get a multi line tooltip in MFC -

unit testing - How to mock PreferenceManager in Android? -