Solved

HOWTO set a value to an invisible input text of a HTML page with an Applet?

Posted on 2001-06-07
2
186 Views
Last Modified: 2010-05-18
Hello!

HOWTO set a value to an invisible input text of a HTML page with an Applet?

thanks
0
Comment
Question by:jussara
  • 2
2 Comments
 

Accepted Solution

by:
smileyxx earned 30 total points
ID: 6165807
In Netscape, you may use Java to JavaScript communication.

For example, in the applet

import netscape.javascript.*;

public void setValue(String value) {
 JSObject win = JSObject.getWindow(this);
 win.eva("document.FormName.HiddenFieldName.value="+value);
}

and in the html,

<form name=FormName>
  <applet ... MAYSCRIPT><!-- mayscript is necessary -->
   <input type=hidden name=HiddenFieldName>
</form>
0
 

Expert Comment

by:smileyxx
ID: 6165901
This will also work in Internet Explorer 4 and above.
All your applet needs is the JSObject class, which you can extract from the java40.jar file distributed with Netscape.
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Hibernate Not Rolling Back When something fails in a stored procedure 2 50
what is a "java.lang.System Property"   ? 20 57
jar file executable 12 37
javap not working 8 36
For beginner Java programmers or at least those new to the Eclipse IDE, the following tutorial will show some (four) ways in which you can import your Java projects to your Eclipse workbench. Introduction While learning Java can be done with…
In this post we will learn how to connect and configure Android Device (Smartphone etc.) with Android Studio. After that we will run a simple Hello World Program.
Viewers learn about the “while” loop and how to utilize it correctly in Java. Additionally, viewers begin exploring how to include conditional statements within a while loop and avoid an endless loop. Define While Loop: Basic Example: Explanatio…
This tutorial will introduce the viewer to VisualVM for the Java platform application. This video explains an example program and covers the Overview, Monitor, and Heap Dump tabs.

929 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

16 Experts available now in Live!

Get 1:1 Help Now