How to create a popup notification in lower right corner of screen

Hi
I am fairly new to GUI building in Java. I am using Netbeans 5.0 and currently developing a desktop application. I wanted to display informational messages from the application to come up in lower right corner of screen - similar to when in MSN or Yahoo messenger if new person signs in. Similar pop-up is also found in Norton when it finishes live update.
Currently I am using JOptionPane.showMessageDialog to do this, but it would be more appealing with messages showing on the side without interrupting the application user.
Can someone point me to what I should look at to achieve this? Any sample code would be great help.
Thanks

Use JFrame from javax.swing package. JOptionPane is a built-in dialog that is located at the center of its parent component. With JFrame u can specify the position of your GUI. Try to read the Sun's java tutorial on Creating GUI with Swing: http://java.sun.com/docs/books/tutorial/uiswing/index.html

Similar Messages

  • A symbol appears in lower right corner of screen???

    I get this symbol appearing in the lower right  of my screen on my w510. It is a capital A with what looks like a "house" around it.  Can anyone tell me what it is and how to get rid of it?
    Tom 
    Solved!
    Go to Solution.

    Hello mate,
    It's just the hotkey feature that means your capslock is on. Just press the capslock key to turn it off and it will go away.
    Knowledge is of two kinds. We know a subject ourselves, or we know where we can find information on it.
    ThinkPad T510 4313-CTO Windows 8 x64 - Intel Core i7-620M - NVIDIA NVS 3100M - 8GB RAM - 240GB SSD- Intel Centrino Ultimate-N 6300 - Gobi 2000.
    ThinkPad Helix 3697-CTO Windows 8.1 x64 - Intel Core i7-3667U - Intel HD Graphics 4000 - 8GB RAM- 256GB SSD - Intel Centrino Advanced-N 6205 - Ericsson C5621gw

  • Amodal dialog box: positioning in lower right corner of screen

    I have what seems a quite common requirement, that is to automatically position an amodal dialog box (CL_ABAP_DIALOGBOX_CONTAINER) to the lower right corner of the screen.
    The logical approach to do this would be to read the screen resolution, deduct the size of the box, and pass the result to the TOP and LEFT parameters of the constructor of the container.
    Unfortunately, I haven't found any documentation of what the values for TOP and LEFT (and for WIDTH and HEIGHT, for that matter) really represent. They're not screen pixels, that's for sure.
    To read the screen resolution, I execute the following code:
    DATA:
      lo_consumer       TYPE REF TO cl_gui_props_consumer,
      ls_metric_factors TYPE cntl_metric_factors.
      lo_consumer = cl_gui_props_consumer=>create_consumer( ).
      ls_metric_factors = lo_consumer->get_metric_factors( ).
    In ls_metric_factors-screen-x and ls_metric_factors-screen-y I get back the screen resolution (x = 1280 and y = 994 on a 1280 x 1024 screen, weirdly, but close enough). Got this from another SDN post, BTW - thanks.
    When I manually position my dialog box to the farthest right lower corner, so that the mouse cursor can just about reach it, the GET_LEFT and GET_TOP methods for the dialog box return LEFT = 1453 and TOP = 387. So, obviously, these values have nothing to do with screen pixels.
    What I did, then, was to calculate a factor between the screen pixels and the TOP and LEFT values - a factor which is different for the X and the Y dimensions. I got:
    - (1453 / 1280) = 1.135 for the x dimension
    - (387 / 994) = 0.389 for the y dimension.
    With these factors, I calculate the initial position of the box as follows:
    l_box_pos_x = ( ls_metric_factors-screen-x * lc_factor_x ) - lc_box_width.
    l_box_pos_y = ( ls_metric_factors-screen-y * lc_factor_y ) - lc_box_height.
    This seems to work fine, at least on my system and my front-end PC, with all supported resolutions from 800 x 600 up to 1280 x 1024.
    It just leaves the question open: Does anybody know what the unit of measure for the sizing and positioning parameters of controls is? Why a box with a width and a height of 100 [whatevers] each is not square, but rectangular?
    And finally: does somebody have a more intelligent way to do this?
    Thanks, regards & stuff
    Rainer

    Hi Rainer,
    While creating the dialogbox container object, just set metric property to '1' (for Pixels) and then while setting TOP and LEFT you can provide pixels.
    For example,
        CREATE OBJECT REF_DIALOGBOX_CONTAINER
            EXPORTING
                WIDTH = 100
                HEIGHT = 100
                TOP = 638
                LEFT = 924
                CAPTION = 'hello world'
    <b>            metric = 1.</b>
    Then your calculation simply becomes,
    l_box_pos_x = ls_metric_factors-screen-x - lc_box_width.
    l_box_pos_y = ls_metric_factors-screen-y - lc_box_height.
    <b>NOTE: Now you will see that your dialog box is a SQUARE!!</b>
    Hope this helps..
    Sri

  • How to create a popup window to load HTML page in AIR application without using any mx or spark?

    How to create a popup window to load HTML page in AIR application without using any mx or spark components?
    I need to load the HTML page in popup in AIR application without using any of the <mx> or <spark> components. I need to open in the application itself not in the browser.(If we use navigateToURL() it will open in th browser)

    Can we achieve this? can somebody help me on this scenario..

  • How to create a popup windown with javascript?

    Hi, every one,
    I made a jsp program. I know we can use win.open, win.close to create, to close a popup window with javascript. But I don't know how to create a popup window ,display some message on this window and there is a button on it for closing this window. Just like follows:
    int mark;
    if(mark==1){
         create popup window, display some message, there is a
    button and click it to close this window.
    } else {
         display error message.
    Any one can help me?
    Thanks in advance.
    peter

    Hi, bdtjdc,
    Thank you for your help and kindness.
    You know, I am a new one in javascript. So,
    1, I only know how to use alert(message) on current page and I don't know how use alert(message) on the next page because I
    need to pass some datas from current jsp page to next one.
    2, when I use the code you gave me as follows, there is no popup window and button:
    if(mark==1){
    %>
    <script language="JavaScript">
    message=message+'enter your message here...<br>';
    message=message+'<form name="form1"><input type="button" name="close" value="close window"
    onClick="window.close()"></form>';
    message='enter your message here...<br>';
    var actwin=window.open("","","menubar=0,width=300,height=300");
    actwin.document.write(message);
    actwin.document.close();
    actwin.focus();
    </script>
    <%
    } else {
    error message;
    if I use the code like this, We have the window and message on it, but there is no button on the window.
    if(mark==1){
    %>
    <script language="JavaScript">
    message='enter your message here...<br>';
    var actwin=window.open("","","menubar=0,width=300,height=300");
    actwin.document.write(message);
    actwin.document.close();
    actwin.focus();
    </script>
    <%
    } else {
         error message;
    What's the problem? Please.
    Thanks again.
    Peter

  • How can I disable the Facebook Notification in Firefox 6 which takes my focal point from what I am typing until I close the notification in the lower right corner.

    When I have Facebook open, I get pop-ups in the lower right corner that tell me that I have new notifications or messages in Facebook. When the little pop-up shows, no matter what I am typing, my cursor is taken away until I click the x to close the pop-up. It is very annoying and slows me down so much. It disables my typing.
    If this cannot be resolved, I will either go back to version 5 or uninstall Firefox completely.

    Do a custom install and install each version in its own program folder to use multiple Firefox versions.
    * https://support.mozilla.com/kb/Custom+installation+of+Firefox+on+Windows
    * https://support.mozilla.com/kb/Installing+a+previous+version+of+Firefox
    Create a new profile exclusively for each Firefox version.<br />
    Create a desktop shortcut with -P "profile" appended to the target to launch each Firefox version with its own profile.
    See these mozillaZine KB articles for information:
    * http://kb.mozillazine.org/Creating_a_new_Firefox_profile_on_Windows
    * http://kb.mozillazine.org/Shortcut_to_a_specific_profile
    * http://kb.mozillazine.org/Using_multiple_profiles_-_Firefox
    * http://kb.mozillazine.org/Opening_a_new_instance_of_Firefox_with_another_profile
    * http://kb.mozillazine.org/Testing_pre-release_versions
    <br />
    ''(in reply of a PM)''

  • How to create a popup window that shows detail information when press submi

    hi,all
    how to create a popup window that shows detail information when press the submit button ?I mean,when I press the button "Sumit"there will appear a popup window that shows the detail information you typed before.it means are u sure to submit,it is like some confirmation window.
    how to do achieve this ?help plz .
    best regards
    hlee
    Edited by: hlee on 2011-4-15 上午1:26

    hey,vee
    thanks for your response,but i had already read this thread before i put up a new question.any way,thanks.
    best regards
    hlee

  • HT5362 How to move the banners from the upper right corner to the low right corner of the screen on Mac (Mavericks)?

    How to move the banners from the upper right corner to the low right corner of the screen on Mac (Mavericks)?
    Sometimes, when I am about to click something in the upper right corner, the banners stand in the way. It is very annoying.
    However, I still need them and it is not an option to completely turn off notifications.
    Has anybody faced the same problem?

    Yeah, i've been playing around a bit with Notifications, and not being able to move there location is very annoying. The default location  normally means it is covering one or more tabs in Safari (or any tabbed application for that matter). Might have to try Growl again.

  • TS3999 In MONTH, (PC) iCal only clearly lists 2 items a day. The 3rd item is "faded" and bottom portion cut off, w/ a "more" triangle in the lower-right corner. How can I expand (vertically) so the 3rd line posts clearly, and ONLY shows "more" if 4+ event

    In MONTH, (PC) iCal only clearly lists 2 items a day. The 3rd item is "faded" and bottom portion cut off, w/ a "more" triangle in the lower-right corner. How can I expand (vertically) so the 3rd line posts clearly, and ONLY shows "more" if 4+ events?
    Better yet... as there's a lot of "wasted" space w/ too large Month title and empty space surrounding the Month title above and too much space surrounding the month/year slider bar below, how can I minimize these to allow me more usable / valuable calendar "contents" so I don't need to waste so much time clicking "more" just to see the bottom of the truncated third event and find out there are no 4+ events posted that date?  i.e. more "user-friendly" presentation?
    Thx!
    [email protected]

    In MONTH, (PC) iCal only clearly lists 2 items a day. The 3rd item is "faded" and bottom portion cut off, w/ a "more" triangle in the lower-right corner. How can I expand (vertically) so the 3rd line posts clearly, and ONLY shows "more" if 4+ events?
    Better yet... as there's a lot of "wasted" space w/ too large Month title and empty space surrounding the Month title above and too much space surrounding the month/year slider bar below, how can I minimize these to allow me more usable / valuable calendar "contents" so I don't need to waste so much time clicking "more" just to see the bottom of the truncated third event and find out there are no 4+ events posted that date?  i.e. more "user-friendly" presentation?
    Thx!
    [email protected]

  • Camera already on from lockscreen on iPhone 5c. How do I turn it off? The camera icon is running in the lower right corner and when I swipe up from the bottom of the lockscreen it brings up the camera running.

    My camera is already running from the lockscreen, the camera icon is displayed in the lower right corner and when I swipe up the control center it brings up the camera first. If I swipe up again I get the control center.  How do I stop the camera from staying on and coming up first?

    I thought the feature was for it to be available for me to use, not to swipe up and have the camera already going. The control panel is not coming up first, it is the camera. In order to get to the control panel I have to swipe up again and the camera is still going. Annoyingly, I have had to disable the camera from the control panel so it isn't coming up first, and now it is unavailable to use quickly.  

  • How to create a transaction code for a function group with screen 100 as st

    Hello ,
    I have requirement where I need to create a function group and create screen 100, 200, 300 and include the function in the screens.
    Customer asked me to create a transaction with the screen 100 as the starting screen.
    Can you please let me know how to create a transaction code for a function group with screen 100 as starting screen.
    [ It is not a module pool program ].
    Thanks
    Prashanth.
    Moderator message - Please ask a specific question and do not ask the forum to do your work for you - post locked
    Edited by: Rob Burbank on Jun 2, 2009 11:49 AM

    Go to transaction SE93, enter a transaction code that you want and click on "create". Enter a text and select the "Transaction with Parameters" button. In the Default Values section, enter START_REPORT in the transaction field. Check the "skip initial screen" box. In the Name of Screen field section enter the following lines:
    Name of screen field:                               Value
    D_SREPOVARI-REPORTTYPE                RW
    D_SREPOVARI-REPORT                        ZPCA
    Save and transport accordingly.

  • How to create application toolbar in modal dialog box in selection-screen

    Hi Experts,
    how to create application toolbar in modal dialog box in selection-screen?
    Regards,
    Swapnika

    Hi,
    Check the following link regarding Model dialog box and appication toolbar
    http://help.sap.com/saphelp_nw70/helpdata/en/d1/801b84454211d189710000e8322d00/frameset.htm
    It helps in solving your problem.
    Thanks.
    Ramya.

  • How to make JFrame positioned to lower right corner of user's desktop

    I'm a new java user, and I'm working on building a small
    application. When the application is launched, I would
    like the application (JFrame) window to be positioned
    in the lower right corner of the user's desktop. Does
    anyone know how to get the user's desktop size so
    I can position the application.
    Here is a code snippet where I lauch the app.
    public static void main(String args[]) {
    ArchiveRestore mainFrame = new ArchiveRestore();
    mainFrame.setSize(500, 500);
    mainFrame.setTitle("Master Model Automation");
    mainFrame.setVisible(true);
    Thanks
    -cliff

    Dimension screenSize = Toolkit.getDefaultToolkit().getScreenSize();
    Will get the screen size. The Toolkit class is in the java.awt package.

  • In the lower right corner of the window there is a column of little white boxes with "9.8" over it what is this and how do I get rid of it?

    In the lower right corner of the window there is a column of little white boxes. Right over the column is "9.8". What is this and how do I get rid of it?

    Please provide a screen shot of that issue.
    https://support.mozilla.com/en-US/kb/Adding+screenshots

  • I'm getting a very low signal from my Blackbird interface. The fire wire connection is selected properly and track recording sliders set. However the recording level slider in the lower right corner is grayed out. How can I get better signal?

    I'm getting a very low signal from my Blackbird interface. The fire wire connection is selected properly and track recording sliders set. However the recording level slider in the lower right corner is grayed out. How can I get better signal?

    If it's slow on startup it would be extensions loading or LaunchDaemons starting up. 
    You should have a look in:
    /Library/LaunchDaemons
    /Library/Extensions
    You can count out anything in your home folder and it shouldn't put anything in /System as that's reserved for Apple. 

Maybe you are looking for