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 6583607
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T16:25:52+00:00 2026-05-25T16:25:52+00:00

I am trying to call a method in a Java applet from JS. I

  • 0

I am trying to call a method in a Java applet from JS. I am a little bit confused about how to arrange my workflow. I have a jsp (pending.jsp) class which includes a javascript (pending.js). pending.jsp is just a container to hold pending.js. pending.js’ purpose is to enable users to cancel report creation.

pending.jsp:

<div id="pending-reports-container" class="pending-reports-container">

    <div id="pending-reports">

    </div>
</div>

pending.js:

function update_pending_reports(response_data)
{ bla }
function delete_report(report_id)
{ bla }
function request_pending_reports()
{ bla }
function start_pending_reports() {
    request_pending_reports();
    setInterval("request_pending_reports()", 5000);
}

Because cancelling reports sometimes is not that efficient I want to use Java to cancel requests that goes to the postgres (pending.js does not kill the process that works at postgres). I created my Java class but I don’t know where to add it. I know I can make use of tag, but when I tried to add this tag to my jsp file like this:

<div id="pending-reports-container" class="pending-reports-container">

    <div id="pending-reports">
       <applet id="LS" width=1 height=1 code ="module/LicenseCheckService.class" codebase="."/>
    </div>
</div>

I can not reach it from my pending.js with this code:

 getJS = document.getElementById("LS");

Is there something wrong with my code or am I wrong at this structure in the first place?

  • 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-25T16:25:53+00:00Added an answer on May 25, 2026 at 4:25 pm

    See the Invoking Applet Methods From JavaScript Code Oracle docs.

    Nutshell version is that the JavaScript refers to the applet object by the applet ID, and can call methods on it.

    appletId.anAppletMethod();
    var anAppletClass = appletId.getAnAppletClass();
    anAppletClass.methodCalled("with a JavaScript string parameter");
    // Etc.
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am trying to call javascript method from an Applet using netscapte.java.JSObject . in
i am trying to call a navite method defined in c++ from java, the
I'm trying to call a class (main method) from command line (Windows) with Java.
I'm trying to get a simple Java method call from C++ while Java calls
I'm trying to call the java code from S. This method call: cls =
I'm trying to call a java method from native C code in an Android
I am trying to make a call to a Parent class method from a
I am trying to call MavenCli from my OSGi plugin project. I have added
I trying to call some ejb bean method from tread. and getting error :
Im trying to invoke a method in java from javascript, but this doesn't happen

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.