Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

haicnpmk44

macrumors newbie
Original poster
Jun 4, 2009
1
0
Hi guys. I call some step below:

//Step1: call a javascript function.
NSString *returnResult = [webView stringByEvaluatingJavaScriptFromString:_scriptMethod];

//Step2: alert return result:
[self alerMessage: returnResult];

The step2 is always called while step1 still does not finish yet. So alert message is empty. (Because of iphone function speed faster than javascript function).

Please help me to run step3 after step1 finish.

Thank you so much.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.