Synchronizing Applet Initialization with JavaScript

In reference to the thread Getting the input values in xacute query
I want to:
1.  pass a parameter value from an HTML form to my xacute query
2.  not have the applet running the query run until after the HTML form's Submit button has been pressed

David,
I hope my response in that thread was helpful.
Regards,
Michael Teti

Similar Messages

  • Call applet method with javascript

    my html - code:
    <APPLET NAME="Mail" ... ... ></APPLET>
    <form action="javascript:document.applets("Mail").test("Execute JAVA Applet Function")">
    <input type="submit" value="Execute Applet Function">
    </form>
    my applet code:
    public void test(String t)
    {System.out.println("executing test()");
    teststr = t;
    repaint();
    in the paint() method i draw the teststr with Graphics.drawString - but nothing happens...
    any suggestions?
    thx

    Directly calling a Java Applet's public method from within
    JavaScript is made possible by LiveConnect which is not implemented by Internet Explorer as of yet. LiveConnect is only available on Netscape navigator at this time.

  • Changing applet parameters with Javascript

    Is it possible to have an applet read a param value which has been changed with Javascript after the applet loads?
    I've tried changing the param value in this way, but the applet doesn't read the new value. It reads the default value in the HTML when the applet loads, and getParameter is in the main loop of the applet which runs and updates other (internal) values fine...

    Well that page says that param values can't be changed at run-time. Never mind though because I read some more and found out how to implement a method in the applet (which can be called from Javascript) that reads the host page's DOM, thereby achieving the same result.
    Thanks for the pointer.

  • Intercepting applet clicks with javascript

    I have an applet that runs in a jsp.
    Is it possible without changing the code of the applet
    to handle events of the applet like onmouseup in javascript?
    For example -when the user clicks on the applet I want to know that
    via javascript.
    Thanks.

    Not sure if it is possible with out changing the Applet code but to do Applet-JavaScript interaction you use LiveConnect
    http://java.sun.com/products/plugin/1.3/docs/jsobject.html

  • How to bypass or modify  WAD initialization with javascript

    Hello WAD Developers
    I want to understand what happens when you load and re-load a page, because I need to invoke some logic only the first time a page is run and not each time you click someone.
    I have created some javascript logic which uses a drop-down to reset a data provider - similar to the Query View Selector item except that I can take advantage of variants. Part of my solution is that I load a drop-down select box from an external list of choices. The BW data part works wonderfully. But what also happens is that my select options load EVERY TIME any event happens on the page. This means that after the data is loaded and the select box is reset, it will not show what was selected. I've tried "first-time only" logic in the function, but since the page refreshes, it's always the first time.
    Any suggestions?
    To show it graphically,
    Here's how the dropdown boxes normally work. Let's pretend my box shows four slots:
    Select a State  <== This is what you see in your box.
    AL
    GA
    FL
    If you select GA, then the next time you might see
    GA           <== Now I'll see the first selected item.
    FL
    IN
    OK
    Select a State  <== Even after a selection,
    AL              <== I always see this
    GA
    FL
    What I have coded the drop-down to do is like this:
    1. In the html itself, there is only one item:
    Selection Goes Here.
    2. After my code loads, by running a function from the <body onload>, I get:
    Variant1
    Variant2
    Variant3  etc.
    If the user selects Variant2, the next time I should see:
    Variant2
    But instead my code shows me:
    Variant1 each time.
    I have code within the function to only load the drop-down when it is in the initial state, but my debugging shows
    me the initial html drop-down values are reset each time. How can I persuade bw NOT to reset this code each time?
    If this is javascript DOM stuff and someone can show me that instead, I'll be greatful.
    Points are awarded, and if you're in Atlanta, I'll even bring you a Coke and a candy bar.
    Thanks in advance,
    Doug Childs

    Hi,
    you could use a wrapper around your Template:
    Your Template is an Iframe in a 'top'-template.
    'onload' in your bw-template you could then chek the upperframe for a variable, which tells you if your function was allready executed.
    Regards,
    Alican

  • Swing based applet communication with javascript

    Hi
    In my browser based application, the GUI has two part one contains the swing based applet and other is html based text area. Applet contains the list of text files.
    My requirements is that if user double clicks on a file the, text area should display the name or path or content of file. I facing problem at very first level, how to capture the swing event in java script of browser?
    Thanks in advance!!! :)

    Hi
    In my browser based application, the GUI has two part one contains the swing based applet and other is html based text area. Applet contains the list of text files.
    My requirements is that if user double clicks on a file the, text area should display the name or path or content of file. I facing problem at very first level, how to capture the swing event in java script of browser?
    Thanks in advance!!! :)

  • Call an applet in other page html with javascript

    Hi
    I found many exemples with javascript, to call applet method in the same html page, but never cross pages
    There is a way to call with javascript an applet in other window/page?
    Thanks

    By other WORKSPACE do you mean another location (as defined in dads.conf)?<br><br>Either way, you just have to make the url relative or just hard code the entire path. If location 1 is pls/htmldb and location 2 is pls/htmldb_two then all you need to do is:<br><br>
    owa_util.redirect_url( '/pls/htmldb_two/f?p=TLL:3:&SESSION.::::F119_TAB_CONDITION:1');<br>
    that is if I understood your question correctly...<br><br>
    chet<br>

  • The combination of report with javascript

    Hi guys,
    I want to use report combined with javascript as follows:
    <APPLET NAME="ASMGridAppAssembly" ...
    PARAM NAME="QueryTemplate" VALUE="..../Reports/PTSD/AsmNCMFRXQuery">
    <PARAM NAME="DisplayTemplate" VALUE=".../Reports/AsmGrid">
    <param name="Param.1" value=>
    <param name="Param.2" value=>
    </APPLET>
    document.ASMGridAppAssembly.getQueryObject().setParam(3,Param3);
    document.ASMGridAppAssembly.getQueryObject().setParam(4,Param4);
    Can I achieve this?
    Thanks,
    Tony.
    Edited by: Tony Hu on Aug 8, 2008 7:07 PM

    Mike - Huh?  If javascript is called to an active applet on the page that received Param.1 and Param.2 through param overrides in the html (like shown in Tony's post) they will absolutely override any static ones that are in the query template itself.
    Tony - you need to instruct the applet to run the query with your 2 new parameters, so add this line after setting param 3 and 4:
    document.ASMGridAppAssembly.updateGrid(true);
    Regards,
    Jeremy

  • Call applet methods from Javascript

    Hello,
    If I call applet method like :
    function callbackFunc(){
        var pp = appletID.getData();
        alert(pp);
    It works only if applet is deployed with <APPLET> tag or with javascript.
    If applet is deployed using <Object> and <embed> tags, in browser console the error is :
    TypeError: appletID.getData is not a function
    I couldn't find why is that behaviour. What do I do wrong?
    Thanks

    Hi Paul,
    (1)Seems to be your Java Runtime Environment path is still setted for JRE 1.3.0_01 and not for 1.3.1. So pelase go to the
    Control Panel-->java plugin 1.3.1-->Advanced. Here you set the Java Runtime Environment to the JRE 1.3.1 version. Its better to remove the older version before installing the new version on JRE.
    (2)<OBJECT> tag won't work for Netscape. You can only use <APPLET> or <EMBED> tag for Netscape.
    Hope this will help you.
    Anil
    Developer Technical Support
    Sun Microsystems
    http://www.sun.com/developers/support

  • Invoking Applet methods from Javascript for Netscape 6

    Hi,
    I am trying to invoke an applet method from javascript, but it is failing with Netscape 6 browser:
    I am doing it the following way-
    function test(form)
    var i = document.myapplet.getname();
    where myapplet is the name of the applet and getname is a method within the applet. This is
    working with Ie but not with netscape 6.
    I would appreciate it if someone could tell me how should I invoke the applet method for netscape browsers.
    Thanks.
    Jay Srin.

    Not working with NS 6 - and will not i guess till they upgrade to Mozilla Version 1.0 - Live Connect is not implemented 100% correct yet - if you want you can download the 7.0 Pre Release Netscape - since its using mozilla 1.0 it should work , see :
    http://forum.java.sun.com/thread.jsp?forum=30&thread=272975

  • Is it possible to add color context row with javascript?

    Hi,
    Is it possible to add color context rows for a graphic object with javascript?
    Thanks.

    The match syntax changed between version 12.0 and 12.1, so my recommendation to you is to build an iGrid template the way you would like to do it with javascript, then export the display template from the workbench. 
    Open the template in a text editor and observe the format for the MatchValues, MatchColumns, and MatchColors strings.
    Then your javascript will follow the document.APPLET.gridObject().setMatchXXX("xxxx"); as shown in the script assistant.

  • Please help with Javascript obejcts hierarchy

    Hi!
    Is following Javascript obejcts hierarchy is right?
    1. App > 2. Doc > 3. Page >
    (from Page) > 3.1 Annotation3D
    (from Page) > 3.2 Field (link)
    thank u )

    You have to have Acrobat/Reader open to open a PDF and use some or all of the Acrobat JS features.
    When Acrobat/Reader is started various folders are accessed and files within those folders read and processed to create the application. This includes dictionaries, certain global variables, various functions provided by Adobe, and user defined functions or variables. The Adobe provided functions or user provided functions or variables are accessed by their assigned name. So if you created an application folder level function in a file called 'hello.js' containing the following code:
    function HelloWorld()
    app.alert('Hello World!');
    return;
    HelloWorld();
    Each time you open Acrobat an alert box with "Hello World!" will appear.  So even without any PDF open one can perform or have a task done. With application level scripts, you can add menu item, tool bar buttons, or modify menu items, etc. So when you open Acrobat you could have a menu item to create a new blank PDF or add the JS API Reference to the "Help" menu item. And if you selected "Help => JavaScript API', the JS API Reference file would open, whether there is an open PDF or not.
    PDF files are opened at the application level, as the application needs to interpret the code of the PDF file and provide the necessary resources for displaying, calculating, linking, etc for the open PDFs. If you open a PDF pragmatically, you need to provide an object name to that PDF. Especially if you are going to reference that file with JavaScript.
    Within an open PDF there are various actions. The first is the document level scripts that are used to establish the environment in which that PDF will function. This could include special functions to sum values, compute date differences, perform special key stroke and formatting. There can even be test to see if there are any necessary application level functions available for use the the document.
    Within PDF document you can can fields, links, comments, etc. And these items only exist in the PDF document and rely on the PDF document for performing the various task or communicating those task the the application.
    By the way with the "HelloWorld" function defined in the application JavaScirpt folder, and PDF opened on that computer can have a button with the 'mouse up' action JavaScript of "HelloWorld();" for the code and any time that button is pressed the alert box that appeared when Acrobat was started will appear. But if you take that PDF to another computer that does not have that file nothing will happen or an error box will appear.
    See Getting Started - Developing for PDF by Dave Wright and look around the Planet PDF site.
    You also need to realize that Acrobat JavaScript does not run synchronously, so you do not always have the individual scripts running in the same order or speed so it is possible a script will not always start and end before the next script in line is started or ends. And if you have dependencies between these scripts you need to test to see if they are all met.

  • Could applet chat with html's textbox?

    I wish that I get code that applet chat with textbox in html, so that I could send some string to database in server by asp method.
    Thank you.
    (for the reason the server provider only gives asp+access. please give me applet/html first. then other suggestion is prefered)
    Thank you again.

    I don't really understand what you're trying to do.
    But applet can call javascript and in this way set
    the value of a textbox. Please see here:
    http://java.sun.com/products/plugin/1.3/docs/jsobject.
    htmlthank you. I have read it eventhough it is out of date.

  • Open and Close Popup With Javascript

    Using Apex 3.2
    I have probably done this loads of times in my old job, but do not have access to the code and today I just can't get it to work properly.
    I have opened a pop up window with javascript
    Now I need to close it and refresh the calling page, but only if it passes the validation on the popup.
    I have a hidden item on my pop up called P7_FLAG.
    I have a page process after validation that sets P7_FLAG to (only set to 1, if passes validation).
    I also have a SUBMIT button.
    So once I click my SUBMIT button the page should look at the validations, if ok, set P7_FLAG to 1, then close the popup and refresh the calling page.
    My current javascript look like this
    <script type="text/javascript">
    function saveChanges(){
    doSubmit('SUBMIT');
    var test = $x('P7_FLAG').value;
    if(test == '1')
    window.close();
    window.opener.doSubmit('REFRESH');
    </script>On my button
    javascript:saveChanges();The problem is that I need to click the SUBMIT button twice.
    First time it sets P7_FLAG
    Second time it closes page and refreshes.
    I have probably made some basic error, but today I cannot see it.
    Cheers
    Gus
    Edited by: Gus C on May 10, 2012 12:48 AM

    <script type="text/javascript">
    function saveChanges(){
    doSubmit('SUBMIT');
    var test = $x('P7_FLAG').value;
    if(test == '1')
    window.close();
    window.opener.doSubmit('REFRESH');
    </script>javascript does not wait for the current action to complete and then perform the next line.
    means in your function call
    doSubmit('SUBMIT');is triggered and it carry on's to next line that is
    $x('P7_FLAG').value;this will not be set because you are setting the value of P7_FLAG to 1 in plsql and trying to check in javascript, which will not work.
    what you need to do is amend your js function like below
    <script type="text/javascript">
    function saveChanges(){
    doSubmit('SUBMIT');
    </script>create a page branch to procedure and make it conditional to when P7_FLAG = 1
    and set the branch source to below
    htp.p('window.close();');
    htp.p('window.opener.doSubmit(''REFRESH'');');

  • Links that open a new window with javascript:void(null); do not work in 3.1

    I've been noticing that any site I go to that opens content in a new window with "javascript:void(null);" will be ignored by Safari 3.1. The links work in Firefox and used to work in Safari as well. Any suggestions?

    General rule of thumb in the Mac universe...
    When Safari is updated most if not all third party add-ons break. That's because most don't play by the rules. The developer thinks they know how to do it better than Apple so they just do it their way. So the first rule of survival is to KNOW what you have installed on your machine at all times. Use something like textedit to create a document listing all of the third party stuff you have installed and religiously update the list. Second rule is to wait a few days before applying an update. Third rule is to visit your third party developers' sites and make sure their little gadget is compatible with the new Safari update.
    Being aware of things will make life much easier for you in the long run.

Maybe you are looking for