Close Webstart Applet Window

Hi,
I am Trying to use jnlp file to launch my form application
and it looks good, all works fine , except one thing
1) When i close form application, the webstart applet window
doesn't close
if you have any idea about that please give me the details ???

Hi,
I am Trying to use jnlp file to launch my form application
and it looks good, all works fine , except one thing
1) When i close form application, the webstart applet window
doesn't close
if you have any idea about that please give me the details ???

Similar Messages

  • Close JavaWebstart applet window

    Hi all,
    I am trying to use Java Webstart to launch my forms applications and it looks good, all works fine, except one thing:
    1) When I close the forms application, the Webstart Applet window does not close..
    Does anyone have an idea how to solve the things? I really like the idea of using Java Webstart to launch my apps.

    These codes will be in html i thnk.
    I mean how to use the method inside the destroy() method??

  • Using separate_frame=true and trying to close the applet window after...

    We are using separate_frame=true and trying to close the applet window (the one with the large gray box) after using the following post-form trigger:
    if :system.last_form = 0 then     
         message('Please wait while Forms closes - '||:system.last_form);     
         web.show_document('/forms/html/close.htm','_self');     
    end if;
    This works fine for the first form we open, but if that same form using Open_Form to open a child form we have a problem. When the child form is closed the user is returned to the parent calling form (which is expected), but then when the parent form is closed the separate applet window fails to close. Any suggestions?

    I guess you mis-interpreted the value of :SYSTEM.LAST_FORM. From the online-help:
    SYSTEM.LAST_FORM represents the form document ID of the previous form in a multi-form application, where multiple forms have been invoked using OPEN_FORM.So LAST_FORM shows always the ID of the last activated form, and this will never be 0 if you issued one OPEN_FORM in your application.

  • Close an applet window

    I have an application which is based inside a JFrame (app creates and displays JFrame). It works fine. I made this into an applet which opens up the JFrame instead and can't seem to close the window. When I tell it to close with client.exit(0) it works on an app but not an applet. How do I stop the applet or at least just the JFrame? Thanks.

    There's Applet.stop().
    I don't know about the details of implementing a JVM in a browser, but I wouldn't be surprised if System.exit() were disabled or not permitted.
    Since the page the applet is in is presumably still visible, ratther than stopping the applet it may be better just to close the JFrame and reset the applet's state, or something. (Just tossing ideas out...)

  • Closing the applet window

    how to close the applet window using a button on the applet

    ravindra.alld wrote:
    how to close the applet window using a button on the appletIs your applet in a web browser? If so the only way to hide visibility of the applet would be through javascript and css. So you would need an html button outside the applet to do this.

  • Closing the Forms Background Page closes the Java-Window as well

    Hi,
    we are running Forms 10g and start the Applet in an separate window. This cannot be changed, because otherwise we lose some size of the Window and the Look and Feel is to different as with Client-Server mode.
    If a User closes the Background-Window or starts a different URL in the Background-Window, the Java Applet is closed directly without any warning.
    This isn't nice for the Users, but they have to live with it.
    But if I'm running a couple of Forms-Sessions in the Applet maybe with Database-Locks as well, and somebody closes the BG-Window, those Forms-Sessions (frmweb.exe) keep running for ~ 5-10 Minutes and the Locks are kept as well.
    Is this behaviour intentional or can it be changed ?
    Any comments are welcome.
    Mark

    Hi Craig,
    in principle I agree that it might be a training issue, but ...
    the default setup for the IE at this customer-site is that Links don't open in a new window. We may change that, but who knows.
    With this setting, the following happens quite normally.
    Forms is started which leeds to the "Background-Window" and the Java-Applet.
    If i minimize all windows and start f.e. Citrix or any other URL-Link, that link is opened in the Background-Window and the Forms-Java-Applet dies.
    In theory this can be avoided by training, but I do not agree, that it is a reasonable behaviour to check all open windows before I start a new URL.
    It just doesn't make sense in my opinion. It might be difficult to solve, but it still doesn't make sense.
    But we've found a solution ourself at least for the accidential closing of the Backgrund-Window :
    In formswegh.cfg we had a line like :
    =======
    HTMLbeforeForm=<_p align=center><_b>nicht schliessen</_b></_p><_p align=center><_b>sonst wird die</_b></_p><_p align=center><_b>Anwendung abgebrochen !</_b></_p>"
    =======
    we added an onBeforeUnload so that it looks like :
    =======
    HTMLbeforeForm=<_BODY onBeforeUnload="return ' Achtung Anwendung wird geschlossen !'"><_p align=center><_b>nicht schliessen</_b></_p><_p align=center><_b>sonst wird die</_b></_p><_p align=center><_b>Anwendung abgebrochen !</_b></_p>
    =======
    This leads to an "Is it OK"-question as soon as the BG-Windows is closed or another URL is called. This prohibits the Users of accident closing. If they still do it, it's their fault and than it is a training question.
    Thanks for your input and maybe this help some others as well.
    Mark
    P.S.
    the underlines before the p's and b's need to be deleted. Just because they are interpreted as HTML otherwise

  • No such element exception when applet window closed

    My applet can throw a NoSuchElementException as it closes during sudden death. The Java Console reports:
    Exception in thread "AWT-EventQueue-2" java.util.NoSuchElementException
         at java.util.LinkedList.getFirst(Unknown Source)
         at java.awt.SequencedEvent.getFirst(Unknown Source)
         at java.awt.SequencedEvent.dispatch(Unknown Source)
         at java.awt.EventQueue.dispatchEvent(Unknown Source)
         at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
         at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
         at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
         at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
         at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
         at java.awt.EventDispatchThread.run(Unknown Source)Sometimes that sequence displays once, sometimes twice. The error appears to be 90% or more repeatable.
    1) open link in new window http://r0k.us/graphics/SIHwheel.html
    2) view Color Log (menu item Help -=> Show Log)
    3) close the whole browser window
    It does not appear to happen without the dialog for the Color Log displayed. Nor does it appear to happen simply upon leaving that page. I'm guessing it is some sort of race condition as the applet is shut down and it doesn't have the surrounding window it started with. It only happens when running as an applet. When ran as a program, it always shuts down cleanly.
    It occurs less often if you:
    1) open the link in new window
    2) leave the page
    ) come back to it while the Java Console is still alive (before JVM goes away)
    3) view the Color Log
    4) close the browser window.
    I am running 64-bit Windows 7, and have observed this problem in Firefox, IE, and Chrome.
    With no hints as to where within my code this is occurring (if indeed it is within "my" code), I have no idea how to write an SSCCE. The exception seems to relate to enumerations, which I believe must be occuring during the shut down seqence. See:
    * http://download.oracle.com/javase/1.5.0/docs/api/java/util/NoSuchElementException.html
    What can I try doing to prevent the error from occurring? (Besides not closing the browser window while my applet is running and has a dialog open. ;) )
    *(added immediately before posting)* I just noticed that if any of the first three dialogs in the Help Menu are open, this behavior can occur. So it probably has nothing to do with the tables in the Color Log. The fourth, About, item is a simpler modal dialog, and you aren't even able to close the browser window while it is open.
    Now that I know the crash can happen with any of the non-modal dialogs, I will write an SSCCE, just to see if it occurs in a much simpler applet, if nothing else.

    As promised, an SSCCE with build instructions and an applet environment.
    CloseMyWindow.java import java.awt.*;
    import java.awt.event.ActionEvent;
    import java.awt.event.ActionListener;
    import java.io.IOException;
    import java.net.URL;
    import javax.swing.*;
    public class CloseMyWindow  extends JApplet
        public JPanel makeContent() {
         JButton help = new JButton("Help");
         help.addActionListener( new ActionListener() {
             public void actionPerformed(ActionEvent e) {
              Dimension size = new Dimension(400, 250);
              HelpBox hb = new HelpBox("CloseMyWindow Help",
                  "cmwHelp.html", false, size);
         JPanel jp = new JPanel();
         jp.add(help);
         return jp;
        // method expected by applets
        public void init()
         try {
             javax.swing.SwingUtilities.invokeAndWait(new Runnable() {
              public void run() {
                  JPanel frame = makeContent();
                  setContentPane(frame);
         } catch (Exception e) {
             System.err.println("makeContent() failed to complete: " + e);
             e.printStackTrace();
        public static void main(String[] args)
            EventQueue.invokeLater(new Runnable() {
                public void run() {
                    JFrame frame = new JFrame("Test");
                    frame.setDefaultCloseOperation(JFrame.DISPOSE_ON_CLOSE);
                    frame.add(new CloseMyWindow().makeContent());
                    frame.pack();
                    frame.setVisible(true);
    class HelpBox extends JDialog
    {   // general window for display of HTML page
        HelpBox(String title, String pUrlS, boolean modal, Dimension pSize)
         super((Frame)null, title, modal);
         final String     urlS  = pUrlS;
         final Dimension     size  = pSize;
         SwingUtilities.invokeLater(new Runnable() {
             public void run() {
              setDefaultCloseOperation(WindowConstants.DISPOSE_ON_CLOSE);
              JEditorPane ep = new JEditorPane();
              ep.setEditable(false);
              try {
                  URL url = getClass().getResource(urlS);
                  ep.setPage(url);
                  JScrollPane eps = new JScrollPane(ep);
                  eps.setPreferredSize(size);
                  getContentPane().add(eps, BorderLayout.CENTER);
              } catch (IOException ioE) {
                  System.err.println("Unable to display help pane");
                  ioE.printStackTrace();
              pack();
              setLocationRelativeTo(null);
              setVisible(true);
    }cmwManifest.txt (be sure to end line with a carriage return) Main-Class: CloseMyWindowcmwHelp.html <html>
    <head><title>Help for CloseMyWindow</title></head>
    <body>
    Good, you've opened this dialog.  Now close the browser window containing
    my applet.
    </applet>
    </body>
    </html>cmw.html <html>
    <head><title>Close My Window</title></head>
    <body>
    <applet code="CloseMyWindow.class"
            archive="CloseMyWindow.jar"
            width="450" height="300">
    Your browser is completely ignoring the <i>applet</i> tag!
    </applet>
    </body>
    </html>1) capture the 4 code segments above and save them as correspondingly-named files.
    2) compile:
    ] javac CloseMyWindow.java
    3) build the jar:
    ] jar cvfm CloseMyWindow.jar cmwManifest.txt *.class cmwHelp.html
    4) test the jar:
    ] java -jar CloseMyWindow.jar
    5) run the applet. Open page cmw.html in a new browser window
    6) enable Java Console (mine is set to autostart on any applet or JNLP)
    7) click the applet's Help button. A new dialog should open up.
    8) close the browser window
    9) observe if an error is reported in Java Console
    I am seeing the error in this small applet. Maybe the .java file will give you guys some clues.

  • Unsigned Java Applet Window

    Hi,
    I have an Applet which can pop-up a JAVA application window.
    But the bottom bar of that pop-up window says " Unsigned Java
    Applet Window". And I am not able to close the window without
    closing the first Applet window. Need some help. Thanks.

    But the bottom bar of that pop-up window says "
    Unsigned Java
    Applet Window". You can't get rid of this without signing
    And I am not able to close the window
    without
    closing the first Applet window. Need some help.you need a window listener (you can use window adapter)
    newFrame.addWindowListener (new WindowAdapter () {
    public void windowClosing (WindowEvent we) {
    setVisible(false);
    dispose();
    Thanks.

  • Empty applet windows on desktop (gnome + compiz)

    Hi,
    After an update a couple of month ago I'm stuck with five empty applet windows starting on the desktop (4x wnck-applet 1x clock-applet). The windows of these applets are really small and are all positioned in the top left of the desktop. This behavoir is very annoying since I have to close these windows manually each time after login. The applets that I do want start up in the panels just fine. Does anybody know what the problem is and how this can be fixed?
    I use gnome and compiz.
    Thanks!

    If you are having problems with your panel you can reset the panel to a default config by moving the copying the current panel config then deleting
    cp -r .gconf .gconf.old
    rm -r .gconf/apps/panel
    Then logout and back in to test.

  • Closing applet window

    i have two Q:
    1) how do i close applet window ?
    2)how can i know that the X button of the applet window was pressed?

    1) You don't...the browser takes care of that!
    2) In IE, the applet's stop and destroy methods are called when the user moves from your HTML to another or the window is closed. In NN4+, the applet's stop method is called when the user moves away from your HTML and the destroy method is call when the window is closed. I don't bother with NN6.2+ because to me it's still a beta product based on Mozilla version .9 something and is so slow.
    V.V.

  • 9i forms_mdi_window maximize doesn't truly maximize Applett window

    When I start a 9i Form it pops up in a separate Applett window, and then the form does a:
    set_window_property(FORMS_MDI_WINDOW,WINDOW_STATE, MAXIMIZE);
    However, this does not exactly maximize the Applett window. It just makes it as big as the whole desktop, which incidentally extends the status bar below the Task Bar/Start Menu on the MS Windows desktop.
    Manually pressing the maximize button on the MDI windows is, however, able to do a maximize. However, setting it programmatically does not work the same as under 6i (which did it correctly).
    Is there a way to actually make it maximize the MDI window programmatically?
    Sincerely,
    Jesper Vad Kristensen
    Aarhus, Denmark.

    I think I have a slightly different problem
    I can still see the staus bar and message bar and the browser window does not obsure the windows task bar.
    The forms window within the java applet does not maximise as it used to in 6i client server.
    Previously the minimise/restore/close buttons were directly under the main runtime window (is that the MDI window?)
    Now there is an extra window bar underneath the menu and toolbar canvas. It is maximised but doesn't integrate itself into the MDI window as previously.

  • Can I close the browser window

    Hi! friends,
    I am in the process of upgrading to forms 6.0
    when we load the form in the webbrowser, is there a
    way I can close the browser window once I exit the form.
    Please advise
    Thanks in advance

    You can try this solution from Metalink:
    Customers want to close the browser's window when they close the forms application.
    Solution Description:
    USE JAVASCRIPT TO CLOSE THE WEBFORM APPLET
    Solution Explanation:
    1.)Create an html file (es. close.html):
    <html>
    <body onload="closeit()">
    <script>
    function closeit()
    window.close();
    </script>
    </body>
    </html>
    2.) Put the html file in the webserver root.
    3.)Inside the Form in a POST-FORM trigger you have to write a WEB.SHOW_DOCUENT builtin like this one: web.show_document('http://mywebserver.com/close.html','_self');
    In this way the web.show_document calls, the JavaScript function "closeit()", when the the applet is closing.

  • Firefox closes existing window when you open and close a new window

    When I'm using firefox and need to open a new window (or a website opens a new window) and I'm done with that new window and close it, Firefox attempts to also close the previous window that I am using. I've tried reinstalling, but other than that I don't know what to do. What usually happens when I close the window is that I have multiple tabs open in the other one and it asks me if I would like to close all my tabs. When I hit cancel, it asks me again. Once I hit cancel the second time it stops bothering me.

    I thought it was doing that also. But I found that if I start a new chat with someone I was messaging before, then the old messages re-appear in the messages window.

  • I always have many tabs open in FF, and rely on it restoring them each time I close/open it again. Sometimes I'll have a second window open and will close the main window first, losing a record of tabs I had open. Is there a way around this?

    Seems like when FF restores a session, it restores the session of the last window open. If you use tabs as a way of keeping a list of things to do or look at, you have to be careful if you have a second window open to close the second window before your main one, or you will lose your list. I'm absent minded though and do this all the time. The only way to prevent this is bookmark all my tabs once a day, but I tend to forget to do even that. Any workaround for this?

    When you re-open Firefox and choose Restore Session, by default it picks up your most-recently-open window, and the other windows should then show up in Recently Closed Windows.
    The Firefox add-on Session Manager lets you manage how many closed windows and closed tabs are saved, in case it's not enough.

  • When I have the downloads window open and I close the browser window, how can I get the browser to open the homepage the next time I start it while the download window is still open?

    When I have the downloads window open and I close the browser window, the next time I reopen the browser while the downloads are still going, it returns me to the last page I was on. All previous versions of Firefox would return me to my homepage which I would prefer. Please let me know if this is possible.

    When you re-open Firefox and choose Restore Session, by default it picks up your most-recently-open window, and the other windows should then show up in Recently Closed Windows.
    The Firefox add-on Session Manager lets you manage how many closed windows and closed tabs are saved, in case it's not enough.

Maybe you are looking for