How to close a window !!!

I want to close a frame by the click of a button.....but donno how. There are two frames, the Parent frame and a baby frame, its ok to give System.exit(0) it closes the parent frame, ....but if I use it for the baby frame that comes from a click of a button of the parent frame then both the frame go to hell....
Hope a champ out there got the answer....
Thanx

babyFrame.setVisible(false);
babyFrame.dispose();

Similar Messages

  • How to close open windows with ios7, How to close open windows with ios7

    How to close open windows with ios7, How to close open windows with ios7?

    Guess they thought we needed more exercise so now we have to swip them to close.....miss iOS6. My eyes are blurry now after looking at my phone, and my arms are tired from swipping lol

  • How to close parent window when we use call method l_window_manager- create

    hi...
    how to close parent window when we use call method l_window_manager->create_external_window
    thank you.

    hi
    good
    go through this link,hope this ll help you to solve your problem
    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/63a47dd9-0b01-0010-3d8e-de27242bf011
    thanks
    mrutyun^

  • How to close ie window?

    hi,
    i need to write a program that could open and close a particular url in ie browser for a particular number of times. i could open the browser using following code
    cmd = WIN_PATH + " " + WIN_FLAG + " " + url;
    Process p = Runtime.getRuntime().exec(cmd);but i could not find how to close the window - please help

    p.destroy()... but how do you decide when to destroy the process -- are you using a timer or whuh?
    By the way, if you just want to open a browser in a platform independent way, you could try the new Desktop [browse |http://java.sun.com/javase/6/docs/api/java/awt/Desktop.html#browse(java.net.URI)] method.

  • How to close child windows when parent window closed in jsp

    how to close child windows when parent window closed in jsp
    becoz it can't be able to recognise it's parent
    with the whole application
    plz send me some sample code of it

    Hi, I have no idea how to do this is JSP.
    However createing a modal window (with javascript) would mean that the user can not use the parent window untill he closes the child window. However not sure if this is what you are searching.
    Otherwise you can detect the onClose (I think) and close the window from there.
    However both the above are JavaScript and not JSP.
    rwgards,
    sim085

  • How to close the window openned by System Exec VI automatica​lly?

    Hello,
    I am using System Exec VI to lauch an exe file built from a LabVIEW program. When running System Exec VI, the window of exe file pop out and stays there even after all tasks are completed. I have to close it every time manually. Anyone here know how to close the exe file window automatically when it's done?
    Thanks,
    Jean
    Message Edited by Jean_CLD on 03-25-2010 11:25 AM
    Message Edited by Jean_CLD on 03-25-2010 11:29 AM
    Solved!
    Go to Solution.

    If I understand the question correctly you need to add an invoke node at the end of your application to exit. Depending on the whether it is running as a stand alone application or within LabVIEW it will either exit or stop execution. I've attached the VI I use in my applications.
    Mark Yedinak
    "Does anyone know where the love of God goes when the waves turn the minutes to hours?"
    Wreck of the Edmund Fitzgerald - Gordon Lightfoot
    Attachments:
    Exit application.vi ‏13 KB

  • How to close a window from program?

    How do I programmatically close a window so that the windowClosing() event is fired? I can't seem to find example code anywhere.
    Thanks, Brad

    Hi Brad,
    This is just a suggestion (I haven't tried it myself), but perhaps the "java.awt.Robot" class can help?
    http://java.sun.com/j2se/1.4.1/docs/api/java/awt/Robot.html
    Good Luck,
    Avi.

  • How to close child windows at logout?

    I was wondering how i can ensure that when a user loggs out,
    any related open child windows from that session are automaticaaly
    closed. The Application is written in ASP VBscript.
    Basically the user can logout two ways, either by clicking on
    the logout link or by closing the browser window. For the latter
    what i did was to create an even for the "onUnload" event of the
    browser. So when the user closes the window, it will also logg the
    user out.
    Now i also wanted to automatically close any child windows
    that the user may have opened when he either loggs out or closes
    the browser window. How can I accomplish that without prompting the
    user that the window is about to close?
    B.T.W. I use the
    window.open method to open the child windows, using either
    javascript or vbscript.

    Hi, I have no idea how to do this is JSP.
    However createing a modal window (with javascript) would mean that the user can not use the parent window untill he closes the child window. However not sure if this is what you are searching.
    Otherwise you can detect the onClose (I think) and close the window from there.
    However both the above are JavaScript and not JSP.
    rwgards,
    sim085

  • How to close browser window after user log out

    Hi,
    Does anyone know how I can close browser window after user logs out. The scenario is when user clicks a log out button I will invalidate user session and close the browser right away in the backing bean.
    Your help would be appreciated.

    Try run this and you'll see that it runs fine with no exceptions:
    <%
         String someText = "bla bla bla";
         response.setContentType("text/plain");
         response.setHeader("Content-Disposition", "attachment;filename=message.txt");
         try {
              ServletOutputStream os = response.getOutputStream();
              os.write(someText.getBytes());
              os.flush();
              os.close();
         } catch (Exception e) {
              out.println("ERROR: " + e);
    %>It looks like that after I've closed the outputStream I can't do any more processing in the JSP. Even if I remove the setContentType and setHeader methods it still behaves this way.
    I'm starting to think that there's no way around this...??

  • How to close a window with a jbutton?

    hi all!
    im have a login box created with jframe,
    what i want is when i press the submit button and if authentication is success
    i'd like to close the jframe of my login box and open a new window.
    how can i close a jframe window with a jbutton?

    to close the window you can add an anynomous class like this:
    yourButton.addActionListener(
          new ActionListener() {
                  public void actionPerformed( ActionEvnet e ) {
                        System.eixt(0);
    );That's all Buddy, Enjoy

  • How to close safari window in iPad?

    I upgraded iPad2 to ios5 and Safari is configured differently.  I can't see how to close an open URL.  Previously, you could touch the little open book that had the number of open windows, and a screen with all the open windows opened.  You could just click on the x in the corner and the URL would close.  Now the open URLs are listed across the screen, and little open book shows no numbers and when you hit it you get History.  So, how to close a URL? 

    You can't close it as such, but you should be able to get it to re-open with a blank tab by first clearing Safari's cache : Settings > Safari > Clear Cookies And Data (Clear Cache on iOS 4) and also Clear History
    And then close Safari completely : from the home screen (i.e. not with Safari 'open' on-screen) double-click the home button to bring up the taskbar, then press and hold any of the apps on the taskbar for a couple of seconds or so until they start shaking, then press the '-' in the top left of the Safari app to close it, and touch any part of the screen above the taskbar so as to stop the shaking and close the taskbar.
    When you re-open Safari you should, hopefully, just have a blank tab.

  • How to close video window without closing iTunes?

    I usually watch video podcasts on iTunes rather than on my iPod. But when the video finishes, how do I close that window without closing iTunes?

    Oops. I just discovered the little white circle with the x in it, that appears in the upper right corner of the video window when the cursor is moved inside the window.

  • When I try to open Firefox, a pop up says it is already running and I must close a window or restart. I can not figure out how to close the window they are asking me to.

    when I try to start Firefox, a pop up says it is already running and I must close a window or restart. I can not figure out what window they want me to close
    == This happened ==
    Every time Firefox opened
    == User Agent ==
    Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.0; WOW64; Trident/4.0; SLCC1; .NET CLR 2.0.50727; Media Center PC 5.0; MDDC; .NET CLR 3.5.30729; .NET CLR 3.0.30618)

    See http://kb.mozillazine.org/Firefox_hangs and [[Firefox hangs]] (Hang at exit)
    Check in the Task Manager (XP: Ctrl+Alt+Del, Vista: Shift+Ctrl+ESC, Processes tab) if there are hanging Firefox processes.
    If you see any ''firefox.exe'' processes then click the End button to end those Firefox processes.
    You can only start Firefox in [[Safe mode]] or launch the [[Managing profiles|Profile Manager]] is all Firefox processes are ended.
    See also http://kb.mozillazine.org/Kill_application

  • How to Close external window?

    Hi Experts,
    1) For one of the development requirements, I am required to open my application in
    external window. For the same, I have changed the property of the iView  and page to
    launch the iView in an external window and not to display in content area. Now, I am
    able to display the application in a new window as per the requirement.
    Now, I want to close this window from a button event on the screen, but can't find a way to close it.
    If anyone's having an idea over it, that will be greatly appreciated???
    2) Also, in another application, I am downloading data into excel sheet and the download
    opens in a new window. Once the user clicks on the option (SAVE, OPEN, CLOSE),
    the blank window should close which works well in IE 7 but in IE 6 the user says the blank
    window is visible and they have to close it manually.
    I am using the following code for this:
    excelCSVFile = new FileInputStream(f);
    IWDCachedWebResource cachedWebResource = null;
    if (excelCSVFile!= null)
    cachedWebResource = WDWebResource.getWebResource
    excelCSVFile, WDWebResourceType.getWebResourceType(
    "xls","application/ms-excel"));
    cachedWebResource.setResourceName(fileName);
    wdContext.currentVn_XL_SheetElement().setVa_Resource(cachedWebResource.getURL());
    workbook.close();
    * BEGIN: Open new window: download button
    IWDWindow win =  wdThis.wdGetAPI().getComponent().getWindowManager().createExternalWindow
    (cachedWebResource.getAbsoluteURL(),"Print Content",false);
    win.setWindowSize(0,0);
    win.removeWindowFeature(WDWindowFeature.ADDRESS_BAR);
    win.removeWindowFeature(WDWindowFeature.MENU_BAR);
    win.removeWindowFeature(WDWindowFeature.TOOL_BAR);
    win.removeWindowFeature(WDWindowFeature.STATUS_BAR);
    win.setWindowPosition(200,200);
    win.show();
    * END: Open new window: download button
    For this if I try win.destroy() or win.close() or win.hide(), after win.show
    this doesn't shows the download options at all (quite obviously   ).
    I want to close this blank window automaticaaly once the user selects
    any option for download. Is there any solution to this or am I doing something wrong?
    Helpful answers will be appreciated. Thanks in advance.
    Regards,
    Gaurav Bhardwaj

    Hi Gaurav,
    If the external window contains the view of the wd component then only you can close the window.
    Try like this:
    Create a context attribute of IWDWindow in the calling view - component - called view and map them in all controllers.
    //set the context attribute  in calling view
    win.show();
    wdContext.currentContextelement().setWinref(win);
    * END: Open new window: download button
    In onActionxxx event of the downlload button
    // close the window
    wdContext.currentContextelement().getWinref().destroyInstance();
    Regards,
    Siva

  • How to close a windows in uix from java

    What is the best way to exit a uix application gracefully?
    I have a uix page with a logon and a close option. Right now the close button triggers an event to call a java method to do a system.exit() which exits the application but leaves the browser window open with a no page to display message.
    I would like to close the browser window first and then exit the application.
    Thanks, Steve

    It can't be done from the server. The only way to programatically close a window is with client-side Javascript.

  • How to close a window correctly?

    I am new to the mac and I have been closing windows using the "x." However, my dock still shows a white circle under such program indicating still in use i.e open.
    Does "x"ing a window not officially close a window?
    Do I have to use the menu bar at the top to officially do such?
    Thanks

    Under Snow Leopard and earlier, closing the window would trigger different application behaviour depending on whether the application functionality was tied to the window (document) or not.
    So applications that could operate without a window (document), like Safari (could be downloading files in the background) or iTunes (could be playing music, downloading from the store, etc, etc) stayed active.  Applications that had no purpose without a window (document) would quit.
    However, it's functionality that the application developer needed to call using the APIs, so it wasn't always consistant with third-party applications.
    In Lion, everything has changed, since the process management model underlying the applications in the operating system is totally different.  Now, even if the "active" dot is on, the OS might kill the process to reclaim resources, under certain circumstances.  And if you quit an application the OS might keep the process alive anyway.
    Heck, I've set my dock preferences to not even show the dot anymore...between application autosave / resume, and this new process management model, the dot just doesn't mean anything anymore.

Maybe you are looking for

  • Switch to a different menu template

    This question was posted in response to the following article: http://help.adobe.com/en_US/premiereelements/using/WS09e4b3c48f3a79fc19b622510385d4355c-7e 00.html

  • Airport Express as Sound card

    Does anyone know how I can get my airport express setup as a sound card that can be selected as the output for other music application other than iTunes? Like DJing software?

  • Grey screen following update to 10.6.8

    Need help. Tried to update to 10.6.8 and all I get is a grey screen

  • Please help on grid computing

    hi aslamo alaikum every body i am a sudent of computer science and receive a project to implement grid computing environment on two servers please can you tell me what steps i take to implement this what software i need and how can i configure a grid

  • Flar Image

    Our IT/CIS section made a .Flar backup (Image) of a SunFire V440 with OS 'Solaris 10 11/06 s10s_u3wos_10 SPARC' and want to port this image to a new M3000 server, but after the installation/setup and a final reboot it gives the next error: Rebooting