Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 691811
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 14, 20262026-05-14T02:35:04+00:00 2026-05-14T02:35:04+00:00

I found a lots of ways to call objective-c code from javascript, but I

  • 0

I found a lots of ways to call objective-c code from javascript, but I want to call the javascript code from objective-c. Last time I submitted a HTML FORM from objective-c, and now I wan’t to call a javascript method. What do you think, is there any way to call it and get the response? I am interested in any solution, but I started to think and I think I need to send a html call or something like this, but I am not sure about this because the javascript is client side code, so maybe I need to process it from my objective-c code.
What do you think about this?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-14T02:35:04+00:00Added an answer on May 14, 2026 at 2:35 am

    Sounds like you are using a WebKit embedded in your app to link JavaScript to your “native” Obj-C code right?

    If so you simply do this:

        NSString* script = @"function __wrapper() { return (typeof webNodeEvent == \"function\") } __wrapper();";
    
        id resultObj = [nodeScriptObject evaluateWebScript:script];
    
        if ([resultObj boolValue]) { // its there, call it
    
            [nodeScriptObject callWebScriptMethod:@"webNodeEvent" withArguments:[NSArray arrayWithObject:eventType]];
    
        }
    

    The nodeScriptObject is from the WebView and is just the JavaScript object.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I found lots of posts regarding estracting a filename from an img-tag, but none
I've found lots of tutorials showing Weld code samples, but not an introductory overview.
I have some code that I want to refactor. I have lots of methods
I've researched and found LOTS of similar requests, but nothing was quite what I
I have found lots of online tutorials but all of them are deserializing JSON
I have found lots of examples of this using XmlNodeList but sadly WP7 does
I have got lots of ideas from google and stackoverflow- but none of those
After lots of attempts and search I have never found a satisfactory way to
I recently found LINQ and love it. I find lots of occasions where use
Found some old code, circa VS 2003. Now I have just VS 2008 (SP1)

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.