Results 1 to 2 of 2

Thread: Calling Objective-C Methods From JavaScript

  1. #1
    Sencha User tomalex0's Avatar
    Join Date
    Apr 2009
    Location
    San Jose, CA
    Posts
    589

    Default Calling Objective-C Methods From JavaScript

    Hi,

    I have came across topic in apple documentation to access Objective C methods from javascript. But i'm not sure how things are working. Did anyone tried this ?.
    Could someone give more idea on this.

    http://developer.apple.com/safari/li...01215-BBCBFJCD

  2. #2
    Sencha User
    Join Date
    Jul 2010
    Posts
    9

    Default

    You can call Objective C methods by invoking URL with custom protocol like document.location="mycustomprotocolname:functionName?param1=value1&param2=value2...".

    Then you must catch such navigation by delegate in UIWebView and if protocol for hyperlink not "http" but "mycustomprotocolname" then parse URL and call needed functions.

Similar Threads

  1. Call Java methods from javascript
    By cabster in forum Ext GWT: Discussion
    Replies: 8
    Last Post: 22 Jun 2010, 11:34 AM
  2. Calling methods from inline html elements!!!
    By swarnendude in forum Ext 3.x: Help & Discussion
    Replies: 4
    Last Post: 16 Apr 2010, 1:18 AM
  3. calling external javascript
    By avilanchee in forum Ext GWT: Help & Discussion (1.x)
    Replies: 0
    Last Post: 17 Feb 2010, 10:29 PM
  4. Calling EXTJS from another Javascript
    By deependhulla in forum Ext 2.x: Help & Discussion
    Replies: 4
    Last Post: 11 Mar 2008, 5:12 AM
  5. Creating javascript classes with methods and properties
    By ApNow in forum Ext 2.x: Help & Discussion
    Replies: 6
    Last Post: 4 Nov 2007, 2:13 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •