• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Running JavaScript in iOS WebView.
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Running JavaScript in iOS WebView.


  • Subject: Running JavaScript in iOS WebView.
  • From: Geoffrey Holden <email@hidden>
  • Date: Wed, 17 Nov 2010 21:33:16 +0000

I've written an app for the Mac (which runs rather nicely) and now I'm trying to port it to iOS (where it won't run at all).  The particular line of code which is causing a problem is this:

	[webView stringByEvaluatingJavaScriptFromString:cmdStr];

cmdStr contains the following: rcs.invoke(dojo.fromJson('{"pw":"password","type":"signIn","email":"email@hidden"}'));

I'm using the JSON framework on Google code (http://code.google.com/p/json-framework/), which (I'm assured) is iOS compatible.  It certainly builds without trouble.

The error I get when this line (fails to) execute is:

void SendDelegateMessage(NSInvocation*): delegate (webViewDidLayout:) failed to return after waiting 10 seconds. main run loop mode: GSEventReceiveRunLoopMode

I have got webViewDidFinishLoad (that's where this code is called) - so it isn't that it's trying to run on nothing.

If you have any ideas about what I could do to fix this, I'd be most interested to hear them!

_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: Running JavaScript in iOS WebView.
      • From: glenn andreas <email@hidden>
    • Re: Running JavaScript in iOS WebView.
      • From: Conrad Shultz <email@hidden>
    • Re: Running JavaScript in iOS WebView.
      • From: Laurent Daudelin <email@hidden>
  • Prev by Date: NSTimer firedate randomly changes
  • Next by Date: Re: NSTimer firedate randomly changes
  • Previous by thread: Re: NSTimer firedate randomly changes
  • Next by thread: Re: Running JavaScript in iOS WebView.
  • Index(es):
    • Date
    • Thread