Find all open windows and close them

Hi,
I'm writing an application that creates a new thread. This thread loads an other application from the filesystem and invokes the main method.
When the thread loads an application that opens a frame, my application can stop the thread, but the frame stays open.
Is there a way that my application can detect if the thread has opened a frame and if there are opened frames that it can close them?

Well, tht's an idea, but my problem is, that my thread can start any aplication by invoking it's main-method.
That means that even my Thread doesn't know which and how many frames it has opened or at least I don't know how I could get a list of all openened frames :-(
A little bit code:
/*Class classToRun is given to the Thread at it's initalisation and already loaded
by a custom ClassLoader, that loads any .class file from a given location*/
classToRun.getMethod("main", new Class[]{String[].class}).invoke(null, new String[]);

Similar Messages

  • Can I save all open windows, and reload them later?

    Hi,
    I work on different projects using different applications.
    Say I am working on recording, and editing an audio. I have Quicktime open, finder(showing files) and GarageBand. Is there anyway I can save the current open windows, so at a later date I can just resume where I left off, rather then having to reopen the finder window, and the applications. It's almost liek I want a snapshot of what's open.
    Is there a 3rd party program that does this?
    Thanks.

    Thanks for the answer, but I would really like to close the apps. I may not return to the project for weeks. That's why I would love if a program could save the current open apps, so when I return to my project. I run this program and boom all of my Finders, and applications are restored the way I left them. It saves me time.

  • How to find all open POs and there SUM

    How to find all open POs and there SUM
    Please help.
    Thanks,
    vihar9

    Have you tried looking at the tables, standard reports, or the PO display transaction?  Have you asked your functional analyst or development team lead? This is not a forum to post a requirement and get your job done for you...

  • I want to reset Firefox, and the message is that something is preventing the reset. I have closed all open windows and I still get the "Oops" message,

    I have uninstalled and reinstalled Firefox because I was receiving unwanted adware and was being directed to untrusted sites. Now I want to reset Firefox because I want to change the home page and toolbars, and something is preventing the reset. I have closed all open windows repeatedly, but the problem continues.
    =====Moved from Firefox OS product to Firefox for Desktop product category by Moderator. -feer56=====

    Check the programs that are on your computer
    '''Windows:''' Start > Control Panel > Uninstall Programs.
    '''Mac:''' Open the "Applications" folder
    '''Linux:'''
    * [http://www.freesoftwaremagazine.com/articles/see_all_your_installed_applications_ubuntu_unity Ubuntu Unity]''' {web link}
    * Xfce: Applications Menu category sections
    * options depends on the package manager and the desktop environment
    Go thru the list. If you find something that you don't
    know what it is, use a web search.
    '''''[https://support.mozilla.org/en-US/kb/troubleshoot-firefox-issues-caused-malware Troubleshoot Firefox Issues Caused By Malware]''''' {web link}

  • I need help identifying and removing annoying gadget that shows all open windows and applications when I mouse over a corner.

    It seemed like a good idea at the time. Some time ago I installed a gadget (doesn't seem to be an item in my Applications folder) which, when I mouse-over the lower-left corner of my screen, brings up a screen showing reduced-size versions of all open application windows and Finder windows. I've tried to identify what it is, and where it is located, so I can remove it, but to no avail.
    I'd really appreciate any help getting rid of this thing. Thanks!

    Hi Paul,
    Check System Preferences>Accounts (Users & Groups in later OSX versions)>Login Items window to see if it or something relevant is listed.
    Check the System Preferences>Other Row, for 3rd party Pref Panes.
    Check the System Preferences>Keyboard>Keyboard Shortcuts.

  • HELP:script that iterates through all opened documents and rezise them to match the biggest one.

    Hi,
    I'm making a batch processing action and I really need a script that iterates through all open documents, finds the one with the biggest image size and then iterates one more time to change the rest of the documents to the same image size dimensions. At the end all documents must share identical image size.  I'll really  appreciate if someone can put a quick script for doing this. Thank you !

    I think should do…
    #target photoshop
    if (documents.length > 1) {
         var smallest = 1000000; // Set beyond any size you may be expecting this should do?
         for (var a = 0; a < documents.length; a++) {
              smallest = Math.min(smallest,documents[a].width.as('px'));
         for (var b = 0; b < documents.length; b++) {
              if (documents[b].width.as('px') != smallest) {
                   app.activeDocument = documents[b];
                   var newWidth = new UnitValue(smallest, 'px');
                   documents[b].resizeImage(newWidth,undefined,undefined,ResampleMethod.BICUBICSMOOTHER);
    }else{
         alert("NOT enough docs to resize?");

  • I purchased extra icloud storage to back up my phone and photos. Purchased a new phone and went to download phtotos on new phone and only a portion of my photos are back on my new phone. How do I find all my photos and get them on my new phone

    I purchased extra icloud storage to back up my phone and phots. Purchased a new phone and went to pull my photos from icloud and only a portion trasferred to my new phone. How do I get all of the photos moved to my new phone?

    Not photos, just data synced with iCloud shown in Settings>iCloud.  If you don't have sufficient storage to back up to iCloud, back up to your computer instead using iTunes (connect you phone to your computer, open iTunes, click on the name of your phone in iTunes, go to ths Summary tab of your iTunes sync settings and click Back Up Now).  Also transfer your purchases to your iTunes library (connect your phone to your computer, open iTunes and go to File>Devices>Transfer Purchases). If you have photo stream photos older than 30 days tha you wan to save, save these to your camera roll before backing up (tap Select, tap the photos, tap the share icon -- box with upward facing arrow, then tap Save to Camera Roll).
    When setting up your new phone, when given the option choose Restore from iTunes Backup and restore the backup you made earlier.

  • Q: How do you sync all open windows and tabs?

    How do you sync all windows and tabs? And if this is not possible, how do you nominate which Windows' tabs are sync'd?
    Sincerely,
    Adam

    You don't have a hot-corner for that anymore.
    You use a gesture for that now. You can either 4-finger swipe down, or place the tips of your fingers in the center of your track pad.  Your fingers should be bunched up and touching each other.  To show all windows, expand your fingers, as if you were showing someone "5" on your fingers.

  • Open Window and Close Window Commands

    I used to use Go Live and I could create buttons to enable the end user to open and or close a pop up window. Is there a way to do this in iWeb? Or is it possible to make a graphic appear on a page whenever you roll over a hot spot or graphic on that same page?
    Thanks,
    Mike Kroesen
    Final Cut Pro Eidtor, Seattle
    [email protected]

    hehe, the first thing i do if i set up a Windows box is to disable all the bleeps dings and whirrs.
    Wondered why i prefered Arch linux/xfce4

  • Assistance with my script to find all opened windows (applications running) on remote computer

    Hello,
    I have the following script whereby I want to list all the running (opened) applications on a remote computer.  It's a shared computer between two people who use the same generic ID.  Before one RDP's into it, I thought it would be interesting
    to see if any apps are opened before logging in. 
    Here is the code:
    $cred = Get-Credential
    Invoke-Command -ComputerName server123 {Get-Process *mail* | Where {$_.MainWindowHandle} | Select Name,MainWindowTitle} -Cred $cred
    It works in that it asks for my credentials and runs without any error...but this script also does not display any running applications. I'm not sure what it should show. Perhaps I need to add a line of code to display what it found?
    Another bit of info I would like to use in this script is to also confirm that the generic ID is logged in at the time I run this script.  I could use the following bit of code:
    get-wmiobject Win32_ComputerSystem -computername server123 | format-table -property username
    But when I run this code I get an access denied message. I'm assuming I need to use the Get-Credential again from my first script, but I'm unsure how to use it in the get-wmiobject?
    Any help you can provide would be greatly appreciated.
    Thank you.

    Ok...shifting gears again.  Instead of running this remotely I'm thinking of running a scheduled task on the server and creating this .htm file.  That way no one has to run and enter in credentials (and if entered wrong cause issues with locking
    out the account).  So, I've modified my script and confirmed that when I run it from Powershell when logged into the server, the results file correctly shows the logged in userid and the running applications (windows) I have opened. 
    But, when I run this same exact script from my task scheduler, the running applications piece is blank?  The server I'm running this on is Windows Server 2008.  I've tried running it from Task Scheduler using Powershell and from a .bat file that
    calls my Powershell script.  Both ways results in my .htm file not showing any applications running.  Yet when I run the same script (either from Powershell or the .bat file) the .htm file correctly shows the running applications.  My Task Scheduler
    Job is using the same user id that I'm logged in with so there shouldn't be any permission issues with running from the task scheduler.
    Here is my code:
    $a = "<style>"
    $a = $a + "BODY{background-color:peachpuff;}"
    $a = $a + "TABLE{border-width: 1px;border-style: solid;border-color: black;border-collapse: collapse;}"
    $a = $a + "TH{border-width: 1px;padding: 0px;border-style: solid;border-color: black;background-color:thistle}"
    $a = $a + "TD{border-width: 1px;padding: 0px;border-style: solid;border-color: black;background-color:PaleGoldenrod}"
    $a = $a + "</style>"
    get-wmiobject Win32_ComputerSystem | ConvertTo-HTML -head $a -body "<H2>Logged in UserID</H2>" -property username | Out-File C:\Powershell_Scripts\Test.htm ; Get-Process |where {$_.mainWindowTItle} |Select-Object name,mainwindowtitle | ConvertTo-HTML -head $a -body "<H2>Open Applications</H2>" | Out-File C:\Powershell_Scripts\Test.htm -Append
    Can anyone tell me what might be the reason for the script running from the scheduled task having issues?
    Thank you.

  • Error message to close firefox appears upon app launch and indicates that a copy of firefox is already open. How do I find the open copy and close it permanently?

    When I go into my daughter's account and try to launch Firefox (she was previously using Safari) an error message pops up indicating to "Close Firefox: A copy of Firefox is already open. Only one copy of Firefox can be open at a time." Except that I don't see an open copy of the app, unless it somehow is launched at login, a setting I don't see either. Firefox works fine on other user accounts.

    Is there still a default profile folder present?
    * /Users/&lt;user&gt;/Library/Application Support/Firefox/Profiles/&lt;profile&gt;/
    If not then delete the file [http://kb.mozillazine.org/profiles.ini_file profiles.ini]<br />
    That will cause Firefox to create a new default profile.
    * http://kb.mozillazine.org/Recovering_a_missing_profile

  • How to find all Open POs and PO status

    Hi,
    1. If I open any PO (we are on ECC6.0), on the PO header status Tab, we can see the status as "Fully Invoiced or Partially Invoiced or Not Invoiced" and similarly for delivery too. Is there any table to see get these statuses directly for any given PO?If no, How do I determine the status manually in the report ?
    2. If you get into a PO, follow the menu path Environment-->AC Commitments docs. Choose Funds Management from the Pop-up. This shall generate a report for the document Jounal entries and display the final amounts (final bdgt) there. Is there any table where I can get this amounts for a given PO?
    I want to generate a report for all the Open POs based on the different statuses from point 1 and also where its AC Commitments-FM docs amount is not equal to 0.
    I checked with my MM consultant for this and he couldnt be of help.
    Thanks
    Kiran

    >
    kiran dasari wrote:
    > But how can I figure out from EKBE or PO history?
    >
    > Do I need to compare the quantities from PO & invoices? If yes, what is the case, if there are multiple accounts for a same line item?...will calculation not be very tedious?
    >
    > Is there any direct shot I can hit to get the status for a given PO and given line item which says....Full Invoiced or Partially Invoiced or Not invoiced and similarly where do I go for delivery statuses?
    >
    > Thanks
    > Kiran
    Yes - it is tedious, but that is what we are paid for. You have to look at each line in the PO history table (EKBE), add up the invoices, subtract the returns. There are also some flags mentioned by other posters to determine whether the PO (or PO item) is complete.
    Rob

  • Close ALL open files and save jpg with jpg option

    Hi,
    I have some (a lot) of -jpg images to crop, and resize, while I have to do this one by one based on what portion of the image to crop, once done I need to close, and save them.
    To speed up the process I open several files, and do the crop&resize, and when finished I use "close all", and would like to avoid to confirm the "save" dialogue, and the "jpeg options" "image quality option" dialogue, having to say save, and the option set to a given value.
    Unfortunatelly I am not a coder, and didn't understand anything from the Javascript Scripting Reference guide.
    I found this
    app.docRef.close(SaveOptions.SAVECHANGES);
    here, I pasted it into ExtendScript, saved it, but when opening the script from file > scripts > browse it returns error 21 (undefined is not an object)
    Will you please kindly give me the script?
    Thank you

    Add this snippet to a script file.
    Load script file in PS scripts folder
    Restart photoshop
    Assign keyboard shortcut to script
    #target photoshop
    //Make Photoshop the formost Appplication
    app.bringToFront();
    // Requires at least one open document
    while (app.documents.length > 0)
         //Save all open windows
        {activeDocument.close(SaveOptions.SAVECHANGES);}

  • Minimizing the application (all open windows)

    Hi,
    I have an application that has more windows (W1, W2, ..., Wn) where W1 calls W2, W2 calls W3 and so on (when Wn is open Wn-1 can not be accessed). I want to minimize all windows when user minimizes Wn. How can I do this? I could use references to all previous windows and minimize them using invoke node, but I don't like this method. Is there any other way to do this? Maybe on the application level?
    Thanks! 
    Solved!
    Go to Solution.

    Hi
    I have an app that has more than one front panel open at the same time, it does create some issues somtimes, for instance when you "alt-tab" through the open windows in Windows.
    To minimize all my Vi's front panel at the same time, there is a button on the main VI, when the user hits it I use this VI (attached) to minimize all the opened FP.
    I'm sorry it's not documented, but basically you have to place it in the main VI of your app and pass in the ref of the main VI, when run, it take take the ref of all the VIs in memory that have their front panel open, minized all of them and old their ref in  the array that's in a shift register and then it wait for the main VI to be opened by the user and then re-displays all other FP that were opened.
    Hope this helps
    When my feet touch the ground each morning the devil thinks "bloody hell... He's up again!"
    Attachments:
    Minimize QMTView.vi ‏17 KB

  • Before I upgraded to 8.0 I could double click and see all open Apps and then close them. Now when I double click I am not sure what I am seeing or what to do?

    Before I upgraded to 8.0 I could double click and see all open Apps and then close them. Now when I double click I am not sure what I am seeing or what to do?

    The format keeps changing but the basics remain...in the center of the screen are large images of the recent apps which you can close by swiping up and away.

Maybe you are looking for