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

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

asp.net - In javascript how to find the height and width -

c# - DataTable to EnumerableRowCollection -