How can find the task bar height of the PC desktop

Hi all,
I want to find the height of the task bar of the PC desktop screen. It can be on any OS such as Windows, Linux, Mac..
I have done something this. Create a JFrame and maximize it by make setVisible to true. Then get the height of it and dispose it. At the same time find the screen height using Toolkit. Then take the difference of it.
My question is, even in the sudden time that JFrame is appear and dispose, it blink on the screen. I want to avoid it. Anybody can give me a solution for it.
Here is my code.
        int screenHeight = Toolkit.getDefaultToolkit().getScreenSize().height;
     final JFrame tempFrame = new JFrame();
     tempFrame.addFocusListener(new FocusListener() {
         public void focusGained(FocusEvent e) {
          tempFrame.dispose();
         public void focusLost(FocusEvent e) {
     tempFrame.setExtendedState(JFrame.MAXIMIZED_BOTH);
     tempFrame.setVisible(true);
     int frameHeight = tempFrame.getHeight();
     int taskbarHeight = screenHeight - frameHeight;
        tempFrame.dispose();Thanks.

needs a bucket load of testing (and possibly only works in java 1.6)
    System.out.println("TaskBar height = " + (Toolkit.getDefaultToolkit().getScreenSize().height -
                 GraphicsEnvironment.getLocalGraphicsEnvironment().getMaximumWindowBounds().height));

Similar Messages

  • How can find the location of my iPad when location services is off?

    How can find the location of my iPad when location services is off?

    If you're wanting to know if you can locate your iPad though iCloud, without Find my device enabled and without power, you won't be able to locate it.

  • How to find the Remote Desktop Client Version?

    How to find the Remote Desktop Client Version in Lion?  I'm asking because in starting up a mid 2011 MacBook Air, I ran Software Update, which determined that Remote Desktop Client version 3.5.1 was available.  I wanted to find what the existing version (older than 3.5.1) that came with Lion was, but coudn't find it.
    Thanks.

    Get Info on:
    /System/Library/CoreServices/RemoteManagement/ARDAgent
    or if you have Apple Remote Desktop on an administrator system, you can see the workstation client versions by control-clicking in the header in the computer list and selecting to show the ARD version column.
    Regards.

  • How can find the difference  between iphone 5 Real Genuine adapter and fake adapter

    Can anyone please tell me, How Can Find Difference between iphone 5 Real Genuine adapter and fake adapter....

    That's about the only way. Many of the fakes are indistinguishable from genuine without taking them apart. See: https://www.youtube.com/watch?v=wi-b9k-0KfE Note that BOTH of the adapters in this video are fake. Yet the one on the left looks identical to the "real thing".

  • How can find the reposite database name connection

    I have a obiee server installed, how can I find the reposite schema database coneection? -thanks

    Hi,
    You can create Repository Static Variable in rpd, and in Connection pool you can mention like VALUEOF(OLAP_DSN) and VALUEOF(OLAP_USER) in DSN and user name.Then create a report and change the function to use these variable.
    fyi..refer:
    http://oraclebi.blog.com/tip-of-the-day-checking-the-dsn-name-and-user-name-from-report-level/
    Thanks
    Deva

  • How can find the Invoice number for GL journal in SQL?

    Dear all:
    I want to ask:
    If I know the GL journal number and also know the journal comes from AP, how can I use the SQL to find out the ap invoice number ,which relevant with this journal?
    my environment is : ORACLE EBS 11.5.9
    Regards
    Terry

    Hello Terry.
    Use the following query:
    SELECT h.doc_sequence_value "Journal Num", l.reference_5 "Invoice Num"
    FROM gl_je_lines l, gl_je_headers h
    WHERE l.je_header_id = h.je_header_id
    AND h.doc_sequence_value = <document number of your journal>
    AND h.je_source = 'Payables'
    AND l.set_of_books_id = <your set of books id>
    Hope this helps.
    Octavio

  • How can find the schema name

    Hi,
    I just want to know,
    based on the sql statements in v$sql, want to know the schema from which the queries are being executed.
    and one more thing,
    one sql procedure/function got failed from the application , I want to know from which schema it got failed and the time when it got failed?
    RR

    You can define the EXCEPTION for any PL/SQL block to catch errors
    http://download.oracle.com/docs/cd/B19306_01/appdev.102/b14261/exception_definition.htm#LNPLS01316
    Kamran Agayev A. (10g OCP)
    http://kamranagayev.wordpress.com
    [Step by Step install Oracle on Linux and Automate the installation using Shell Script |http://kamranagayev.wordpress.com/2009/05/01/step-by-step-installing-oracle-database-10g-release-2-on-linux-centos-and-automate-the-installation-using-linux-shell-script/]

  • How can find SCN or sequence number on the update operation?

    nedd to recovery database, how can find the SCN or sequence number before the update exection?
    thanks

    nedd to recovery database, how can find the SCN or
    sequence number before the update exection?Sorry - there is something confusing about your question ...
    It seems to me the SCN is the 'system change number', which identifies when a change (table, row, block, flush log buffer to log file, etc) has ocurred.
    You seem to be asking for the SCN associated with an update before the update actually occurred.
    Are you actually asking "How do I perform a point in time recovery to immediately before a specific update?"
    Perhaps you could include a few more details, such as database version. For some reason different versions have different capabilities - that could be helpful here.

  • How can find  database field and table name

    how can find the underline database field name,table name from java page. Example. in oracle apps when we go purchaseing super user then supplier base then supplier and find supplier detail .

    Hi,
    depends on your model. If you work with ADF BC then you can use ViewLinks to access parent or detail infromation programmatically. See the developer guides for more information. Note that you wont access the tables directly but the collections that represent the records
    Frank

  • I had purchased Imovie today I can find the icon movie it click it but it will not open. Its shows up in docs and purchased but not apps? how do i add it to my bar and open it?!

    I had purchased Imovie today I can find the icon movie it click it but it will not open. Its shows up in docs and purchased but not apps? how do i add it to my bar and open it?!

    Exactly where are you clicking, you need to be specific. For example, are you using the Dock, the Applications folder, Launchpad, etc. to attempt to start teh app? Also IOS 7.1.2 does not run on a Mac, what version of OS X is installed on your computer?

  • I put in my memory card to the left side of the computer, but I cannot find the file of pictures anywhere. Its not even on my desktop. What should I do and how can I get it to show up on my desktop?

    I put in my memory card to the left side of the computer, but I cannot find the file of pictures anywhere. Its not even on my desktop. What should I do and how can I get it to show up on my desktop?

    If your Mac is new-ish and has one of the Lions as its OS, the drives, cards, USB sticks no longer show up, even though they're there. Go to Finder's Preferences and tick the corresponding items in the General and Sidebar tabs.

  • HT200285 I want to change my wallpaper to an image that was available before I upgraded to IOS 8.1.3 - a close-up image of long reedy  grasses with hazy light in the background. Greyish hues. Where can find the image & how do I get it back on my phone?

    I want to change my wallpaper to an image that was available
    before I upgraded to IOS 8.1.3 - a close-up image of long reedy  grasses with hazy light in the background.
    Greyish hues. Where can find the image & how do I get it back on my phone?

    I want to change my wallpaper to an image that was available
    before I upgraded to IOS 8.1.3 - a close-up image of long reedy  grasses with hazy light in the background.
    Greyish hues. Where can find the image & how do I get it back on my phone?

  • In which table we can find the relationship between Role id and Task id

    Hi Experts,
    In which table we can find the relationship between Role id and Task id in Cprojects.
    Thanks
    Subhaskar

    Hi Subhaskar,
    Apart from DPR_ENTITY_LINK , you can also get it from table DPR_PART.
    Please go through the below link
    http://wiki.sdn.sap.com/wiki/display/PLM/cProjectstablesin+SAP
    I hope this will help you.
    Regards,
    Rahul

  • How i can find the execution plan

    how i can find the execution plan for a quesry , and how i can compare two execution plan

    Mohan,
    Just create a table as follows
    CREATE TABLE T1 (STATEMENT_ID VARCHAR2(30),TIMESTAMP DATE,OPERATION VARCHAR2(30),
              OPTIONS VARCHAR2(30),OBJECT_NAME VARCHAR2(30),COST NUMBER(38),
              ID NUMBER(38),PARENT_ID NUMBER(38), OBJECT_NODE VARCHAR2(128),
              OBJECT_OWNER VARCHAR2(30),OBJECT_INSTANCE NUMBER(38),OBJECT_TYPE VARCHAR2(30),
              OPTIMIZER VARCHAR2(255),SEARCH_COLUMNS NUMBER,POSITION NUMBER(38),
              PARTITION_START VARCHAR2(255),PARTITION_STOP VARCHAR2(255),PARTITION_ID NUMBER(38),
              CARDINALITY NUMBER(38),BYTES NUMBER(38),OTHER_TAG VARCHAR2(255),
              OTHER LONG,REMARKS VARCHAR2(80),DISTRIBUTION VARCHAR2(30)
    Now use the sql statements as
    > EXPLAIN PLAN INTO T1 FOR (SELECT * FROM EMP);
    > Select * from T1
    this should do the job . . .
    Regards,
    K.T. Gandhi Karuna

  • HT1386 My iOS isn´t in device on the left hand, how can find it? or is it that is not connecting properly to the computer

    My iOS isn´t in device on the left hand, how can find it? or is it that is not connecting properly to the computer

    You need to update to 10.6.8 using Software Update.

Maybe you are looking for

  • Save and Cancel are being cut off below the screen

    Hi, I'm trying to download a pdf that has opened in the Safari browser. Cmd Shft S for 'Save As.' The "Save" and the "Cancel" buttons are cut off below the screen. This has happened in iTunes and I simply go to Window > Zoom and it's fixed. In Safari

  • Mapping Problem Please help me

    After deploying my Mapping script I get the following messages: PL-SQL: ORA-00942 Table or view doesn't exist. and consequently I can't deploy and run my script. Does anybody have any idea. I have installed the OWB runtime and repository properly. Re

  • Probably a simple solution, but . . .

    Hi there - There is probably a simple fix to this - and it probably doesn't even matter, but I'm curious. When I attach an exported file to an email, it is attaching as a picture of the document, rather than as an icon with the document's name. The t

  • HT1657 What happens if my AppleTV looses connectivity with Apple Stopre BEFORE my movie finishes?!  I am unable to watch the movie now!  Do I get  charged?

    My Apple TV suddenly stopped in the middle of a movie and notified me that it had lost contact with Apple Store.  I reconnected and it did not recognize I had already paid for a rental.  So I tried to rent it again and it again told me it had lost co

  • L355-S7812 Keeps Restarting on it's own

    I'll try make this as concise as I can.  My laptop restarts on it's own. Often times right after I wake it up from sleep and other times completely randomly. I had replaced the hdd recently so I thought it might of been a bad hdd but then I switched