Make a Panel disappear and appear again

Hi Team
I have a frame with Grid Layout where I have 3 Panels - P1, P2 and P3. I want that on the click on a button "+" P2 should disappear and P1 and P2 should align together. Again when the user click "-" button, P2 panel should appear again in its place between P1 and P3.
The problem with the visible(false) method is that it makes P2 Panel disappear but the space between P1 and P3 panels is still there.
Could anybody help me with this trivial issue
Thanks,
Mo

user13019661 wrote:
Hi Team
I have a frame with Grid Layout where I have 3 Panels - P1, P2 and P3. I want that on the click on a button "+" P2 should disappear and P1 and P2 should align together. Again when the user click "-" button, P2 panel should appear again in its place between P1 and P3.
The problem with the visible(false) method is that it makes P2 Panel disappear but the space between P1 and P3 panels is still there.
Could anybody help me with this trivial issue
Thanks,
MoIn stead of making the panel invisible, remove it from the frame and trigger the frame to layout again (for example by calling pack() or revalidate()).

Similar Messages

  • I have set up home sharing on both home computers, but as soon as I did this, the "shared" title on the left hand panel disappeared and I can't find it again.  Any ideas?

    I have set up home sharing on both home computers, but as soon as I did this, the "shared" title on the left hand panel disappeared and I can't find it again.  Any ideas?

    I have the same problem - can anyone help??

  • Wiki postgres Socket disappears and appears

    Can anybody confirm what I have to experience every time I ....
    I am trying to connect to the postgres-database from Wiki via CLI:
    bash-3.2# ls -la PostgresSocket/            
    total 8
    drwxrwxr-x  3 _teamsserver  _teamsserver  102 Jan 21 19:59 .
    drwxr-xr-x  8 _teamsserver  _teamsserver  272 Jan  9 14:21 ..
    lrwxr-xr-x  1 _teamsserver  _teamsserver    5 Jan 21 19:59 .xpg_ctl.pid -> 75527
    bash-3.2#
    bash-3.2#
    bash-3.2#
    bash-3.2# psql -h "/Library/Server/Wiki/PostgresSocket" -p 5432 -d collab -U collab
    psql: could not connect to server: No such file or directory
      Is the server running locally and accepting
      connections on Unix domain socket "/Library/Server/Wiki/PostgresSocket/.s.PGSQL.5432"?
    bash-3.2#
    Then I did this:
    bash-3.2# psql -h "/Library/Server/Wiki/PostgresSocket" -p 5432 -d collab -U collab
    psql (9.3.5)
    Type "help" for help.
    collab=#
    Boom - connected!!??
    Then I disconnected and "lsed" again - wow!!
    collab=# \q
    bash-3.2# ls -la PostgresSocket/
    total 24
    drwxrwxr-x  7 _teamsserver  _teamsserver  238 Jan 21 20:03 .
    drwxr-xr-x  8 _teamsserver  _teamsserver  272 Jan  9 14:21 ..
    srwxrwx---  1 _teamsserver  _teamsserver    0 Jan 21 20:03 .s.PGSQL.5432
    -rw-------  1 _teamsserver  _teamsserver  103 Jan 21 20:03 .s.PGSQL.5432.lock
    srw-rw----  1 _teamsserver  _teamsserver    0 Jan 21 20:03 .xpg.skt
    lrwx------  1 _teamsserver  _teamsserver    5 Jan 21 20:03 .xpg.skt.lock -> 75696
    lrwxr-xr-x  1 _teamsserver  _teamsserver    5 Jan 21 20:03 .xpg_ctl.pid -> 75731
    bash-3.2#
    bash-3.2#
    bash-3.2# psql -h "/Library/Server/Wiki/PostgresSocket" -p 5432 -d collab -U collab
    psql (9.3.5)
    Type "help" for help.
    collab=# \q
    Everything seems to work, right - suddenly?!
    A couple minutes later
    bash-3.2# psql -h "/Library/Server/Wiki/PostgresSocket" -p 5432 -d collab -U collab
    psql: could not connect to server: No such file or directory
      Is the server running locally and accepting
      connections on Unix domain socket "/Library/Server/Wiki/PostgresSocket/.s.PGSQL.5432"?
    bash-3.2#
    bash-3.2# psql -h "/Library/Server/Wiki/PostgresSocket" -p 5432 -d collab -U collab
    psql: could not connect to server: No such file or directory
      Is the server running locally and accepting
      connections on Unix domain socket "/Library/Server/Wiki/PostgresSocket/.s.PGSQL.5432"?
    bash-3.2#
    bash-3.2# psql -h "/Library/Server/Wiki/PostgresSocket" -p 5432 -d collab -U collab
    psql: could not connect to server: No such file or directory
      Is the server running locally and accepting
      connections on Unix domain socket "/Library/Server/Wiki/PostgresSocket/.s.PGSQL.5432"?
    bash-3.2#
    bash-3.2# psql -h "/Library/Server/Wiki/PostgresSocket" -p 5432 -d collab -U collab
    psql: could not connect to server: No such file or directory
      Is the server running locally and accepting
      connections on Unix domain socket "/Library/Server/Wiki/PostgresSocket/.s.PGSQL.5432"?
    bash-3.2#
    bash-3.2# ls -la PostgresSocket/
    total 8
    drwxrwxr-x  3 _teamsserver  _teamsserver  102 Jan 21 20:09 .
    drwxr-xr-x  8 _teamsserver  _teamsserver  272 Jan  9 14:21 ..
    lrwxr-xr-x  1 _teamsserver  _teamsserver    5 Jan 21 20:09 .xpg_ctl.pid -> 76124
    bash-3.2#
    bash-3.2# psql -h "/Library/Server/Wiki/PostgresSocket" -p 5432 -d collab -U collab
    psql: could not connect to server: No such file or directory
      Is the server running locally and accepting
      connections on Unix domain socket "/Library/Server/Wiki/PostgresSocket/.s.PGSQL.5432"?
    bash-3.2#
    bash-3.2# psql -h "/Library/Server/Wiki/PostgresSocket" -p 5432 -d collab -U collab
    psql: could not connect to server: No such file or directory
      Is the server running locally and accepting
      connections on Unix domain socket "/Library/Server/Wiki/PostgresSocket/.s.PGSQL.5432"?
    bash-3.2#
    bash-3.2# psql -h "/Library/Server/Wiki/PostgresSocket" -p 5432 -d collab -U collab
    psql: could not connect to server: No such file or directory
      Is the server running locally and accepting
      connections on Unix domain socket "/Library/Server/Wiki/PostgresSocket/.s.PGSQL.5432"?
    bash-3.2#
    bash-3.2# psql -h "/Library/Server/Wiki/PostgresSocket" -p 5432 -d collab -U collab
    psql: could not connect to server: No such file or directory
      Is the server running locally and accepting
      connections on Unix domain socket "/Library/Server/Wiki/PostgresSocket/.s.PGSQL.5432"?
    bash-3.2#
    bash-3.2# psql -h "/Library/Server/Wiki/PostgresSocket" -p 5432 -d collab -U collab
    psql: could not connect to server: No such file or directory
      Is the server running locally and accepting
      connections on Unix domain socket "/Library/Server/Wiki/PostgresSocket/.s.PGSQL.5432"?
    bash-3.2#
    WHAT?! Socket is gone?!
    A couple minutes later - guess what - yes! Back again!? I swear I didn't do anything - except waiting!
    bash-3.2#
    bash-3.2# psql -h "/Library/Server/Wiki/PostgresSocket" -p 5432 -d collab -U collab
    psql (9.3.5)
    Type "help" for help.
    collab=#
    collab=#
    collab=#
    collab=#
    collab=#
    collab=# \l
    server closed the connection unexpectedly
      This probably means the server terminated abnormally
      before or while processing the request.
    The connection to the server was lost. Attempting reset: Succeeded.
    collab=#
    collab=# \l
                                       List of databases
       Name    |    Owner     | Encoding | Collate | Ctype |       Access privileges      
    -----------+--------------+----------+---------+-------+------------------------ -------
    collab    | collab       | UTF8     | C       | C     |
    postgres  | _teamsserver | UTF8     | C       | C     |
    template0 | _teamsserver | UTF8     | C       | C     | =c/_teamsserver              +
               |              |          |         |       | _teamsserver=CTc/_teamsserver
    template1 | _teamsserver | UTF8     | C       | C     | =c/_teamsserver              +
               |              |          |         |       | _teamsserver=CTc/_teamsserver
    (4 rows)
    collab=#
    Can anyone explain what is going on here, please?

    I use attached files a lot in my wikis. I have the same sort of problem with the question mark graphic. When I refresh the browser, that always fixes the graphic. The problem makes no difference to functionality, but it does make the wiki appear buggy and unprofessional. I will also try to see if file type makes a difference . . .

  • Since I upgraded to the latest os my spotlight doesn't seem to work anymore and the headings across the to keep disappearing and appearing

    Since I upgraded to the latest os my spotlight doesn't seem to work anymore and the headings across the to keep disappearing and appearing

    I think I figured out Firefox, I went under Help > Troubleshooting Information > Reset Firefox.
    I only have one account on my computer. Honestly I don't even really know how multiple accounts work. I've never played around with it. I already allowed Java - should I disable it?

  • I have a mac book air where in when i delete an email the sender ids from all other emails disappears and then again appears in a few seconds.

    There is this strange thing happening with my Mac book air.Whwnever i delete a mail fro the inbox or send folder,the sender or receiver ids disappear from all others just to reappear after a few seconds.This started happening after i received a mail enquiring about some products i sell online.i replied to the mail taking it as a legit enquiry.
    I did not open any attachment with the mail.Am i been hacked.

    Welcome to Apple Discussions
    I believe you have a failing GPU (aka Video Card). Run AHT and see what it tells you. Do not be afraid to run it up to three times in succession if at first it does not detect an error (sometimes errors that are caused by overheating will not show up until the computer is stressed enough - repeating AHT will do that).
    As an aside - the MBA was not designed to take the place of a desktop. If you are powering your MBA by leaving it permanently attached to the thunderbolt port on the monitor you are shortening your battery life.

  • How to make an effect stop and start again?

    How do I make an effect start stop and than start again?
    I'm trying to blur faces (I finally figured out how to do that---copy the video to a 2nd layer and use the mosiac and crop effects) but how do I make the effect only appear when the face is in the screen as multiple times throughout the video clip the subjects face goes off camera.  In the effect controls window it doesn't give me an option to add a blank keyframe.
    Any advice on how to have this effect start/stop multiple times in one clip??
    Thanks

    If the effect isn't keyable, try keyframing the transparency of the copy with the effects on it.

  • How to make a tabstrip visible and invisible again?

    Hi
    I have a GUI with Fields, Texts, Checkboxes, Radio buttons, a Button and of
    course a tabstrip with 7 tabs.
    Before I want to show some data in the tabs of the tabstrip, I have to fill the fields, check a radio button and checkboxes. After filled all entries needed, I will start
    the preparation of the data with clicking on the button.
    Before the click on the button the tabstrip has to be invisible. After the preparation
    of the data I will make the tabstrip with its tabs visible.
    All this is in the same dynpro (e.g. 0100). I don't build it together with to dynpros.
    I tried with LOOP AT SCREEN ... ENDLOOP, but the tabstrip does not appear.
    The only attribute accessable is "activetab".
    How to make that happen?
    Thanks for your help
    Frowin

    Hi
    Suppose you have 3 screen:
    - 1 main screen (100)
    - 2 subscreen    (101, 102)
    In the subscreen 101 you need to design your tabstrip (so you need to move your tabstrip from main screen), the subscreen 102 has to be empty.
    In the PBO of screen 100:
    PROCESS PBO.
    MODULE SET_SUBSCREEN.
    CALL SUBSCREEN SUBAREA INCLUDING V_REPID V_SCREEN.
    In the module SET_SUBSCREEN, you insert the code you need to choose the right subscreen:
    IF _SHOW = 'X'.
      V_SCREEN = '0101'.
    ELSE.
      V_SCREEN = '0102'.
    ENDIF.
    The flag _SHOW is setted in PAI after pressing the button:
    MODULE USER_COMMAND.
        CASE OK_CODE.
           WHEN 'SHOW'. _SHOW = 'X'.
    Max
    Edited by: max bianchi on Jan 9, 2008 5:03 PM

  • How do I make a routine stop and start again without restarting labview?

    I am running Labview 6i and am somewhat of a noob.  I have a subVI designed to take information and write it in a file, but every time I stop this subVI it will not start again until I restart the entire VI.  I would like to be able to start it and stop it and take multiple readings because I must leave the main VI running.  The subVI is attached.
    Solved!
    Go to Solution.
    Attachments:
    Saveas.vi ‏23 KB

    I tried a couple of case combinations, and this one seems the most solid.  Still, the while loop is not passing information.
    Attachments:
    Saveas.vi ‏27 KB

  • Ipad sound mutes suddenly and appears again.

    My ipad suddenly mutes from time to time. I can't hear music or hear sounds from a video. The keyboard clicks are heard time to time too. And sound suddenly appears from time to time. I need Help.

    Try A and B
    (A) Restart iPad
    1. Hold down the Sleep/Wake button until the red slider appears.
    2. Drag the slider to turn off iPad.
    3. Turn iPad back on, hold down the Sleep/Wake until the Apple logo appears
    (B) Reset iPad
    Hold down the Sleep/Wake button and the Home button at the same time for at least ten seconds, until the Apple logo appears
    Note: Data will not be affected.

  • Making Multiple Panels invisible and visible

    So I have this problem, Im trying to make different panels visible and invisible by the means of a button. I believe my code is sound, but its not working. I would really appreciate it if someone were to look at my code and solve this problem. Basically my button isnt working.
    import java.awt.image.*;
    import java.awt.geom.*;
    import javax.swing.*;
    import java.awt.*;
    import java.awt.event.*;
    import java.util.Scanner;
    public class panels extends JFrame
    private JPanel panel1, panel2, panel3, panel4;
    private JLabel title;
    private JButton test;
    public panels ()
    setSize (400,800);
    JButton test = new JButton ("test");
    title = new JLabel ("");
    JPanel panel1 = new JPanel();
    panel1.setPreferredSize(new Dimension(200,200));
    panel1.setLayout (new GridLayout(5,2));
    panel1.setBackground(Color.black);
    JPanel panel2 = new JPanel();
    panel2.setPreferredSize(new Dimension (200,200));
    panel2.setBackground(Color.red);
    JPanel panel3 = new JPanel();
    panel3.setPreferredSize (new Dimension (200,200));
    panel3.setBackground(Color.orange);
    JPanel panel4 = new JPanel();
    panel4.setPreferredSize(new Dimension (200,200));
    panel4.setBackground(Color.green);
    Container container = getContentPane ();
    container.setLayout (new GridLayout(4,1));
    container.setBackground (Color.white);
    container.add(panel1);
    panel1.add(test);
    container.add(panel2);
    container.add(panel3);
    container.add(panel4);
    ButtonHandler handler = new ButtonHandler ();
    test.addActionListener (handler);
    setVisible (true);
    public static void main (String args[])
    panels application = new panels ();
    private class ButtonHandler implements ActionListener
    public void actionPerformed (ActionEvent event)
    if (event.getSource () == test)
    panel1.setVisible(true);
    panel2.setVisible(false);
    panel3.setVisible(false);
    panel4.setVisible(false);
    }

    Take a look at this example and you will see that your code is missing a few things.
    http://www.javaprogrammingforums.com/java-swing-tutorials/278-how-add-actionlistener-jbutton-java-swing.html
    There are plenty of examles on the web of how to do that
    http://www.youtube.com/watch?v=GvTZ2Huo0T4

  • I am running Windows 7 (64bit) , and an error message appears following a recent update to iTunes v 11.1.2:  "iTunes could not connect to the iTunes store. An unknown error occured (-3212). Make sure your network connection is active and try again." help!

    I am running Windows 7 (64bit) , and an error message appears following a recent update to iTunes v 11.1.2:  "iTunes could not connect to the iTunes store. An unknown error occured (-3212). Make sure your network connection is active and try again." I have dug a little bit into possible problems but haven't found a solution yet, one note is that the network connection is OK. A response would be highly appreciated!  Thanks in advance.

    Hi c1r1g1,
    If you are having an issue connecting to the iTunes Store, you may find the following article helpful:
    Apple Support: Can't connect to the iTunes Store
    http://support.apple.com/kb/ts1368
    Regards,
    - Brenden

  • My forwart text feature on IOS 8 keeps disappearing and the only way I know how to make it re-appear is by powering off and on my phone, is there another way to fix this feature?

    my forward text message feature on IOS8 keeps disappearing and the only way I know to make it re-appear is by powering off and on my phone. Is there any other way to fix this?

    I should also point out that when I connect my iPhone, it DOESN'T appear as a connected drive on the desktop. Not sure how this can be so, since the iPhone also has a drive and also functions as an iPod if I want it to. I must have changed some setting to achieve this non-appearance, but don't remember what I must have done.
    What's the secret?

  • Network icon disappear...and It appears again when I remove the battery!

    Hi to everyone.
    This "strange" issue appears now on a lot of pcs so it must be something that someonelse have experienced...
    WIndows XP SP3 with italian multilanguage installed, pcs are Lenovo T400, X200 and  X200 tablets.
    Sometime happens that the network icon (wireless and lan) doesn't appear on the taskbar, and when this happens you are not able to open the network connections.
    The "funny" thing is that if you remove the battery from the laptop, the network icon appear again and network connection magically opens! I've tried to update pcs drivers but without any remarkable result.
    Has someone reported a similar issue?

    Any suggestions on what this can be?
    A dead battery.  Buy a new one.

  • Menu tabs disappear completely after login and appears if only i press on item node at hire level

    I'm using a Menu Model to Create a Page Hierarchy in my adf application on Jdeveloper 11.1.2.3.0
    it is in three levels level 1 have 2 item nods (home - Help) displayed as buttons
                                level 2   contains 5 item nods about the managements displayed as tabs
                                level 3   is about reports displayed as list
    the point I have apply security in the application using Adf security wizard and i assign roles and users and grants
    all works fine but level 2 tabs disappear completely after login and appears if only i press on Home item node at run time
    I create 2 users (admin) has all roles  and can view all  tabs in level 2 of my navigation and another user (emp)  which can view one Tab page in level 2
    Point 1 --the item nod are rendered according the #{securityContext.regionViewable['oracle.view.pageDefs.RentManagPageDef']}     (EL ) expression language 
    and other item nod render property are set as the same but in the page name definition
    it works fine
    _ Point 2 in my page template I set #{menuInfo.rendered} for renderd property of the command navigation item
    it works fine
    - point 3 I add a  go link in my template to explicit perform log in log out from the app  and redirect the user to the required page
    Destination is
    #{securityContext.authenticated ? "/adfAuthentication?logout=true&end_url=/faces/wearhouse.jsf"  : "/adfAuthentication?success_url=/faces/company.jsf"}
    and its also works fine
    the problem is in the level 2 navigation tabs which is diaper after explicit log in the app directs the user to the correct page successfully
    But the tabs are not rendered till I press on home button on Level 1 navigation it appears and it appears  correctly cording the logged in user validation
    in another words i log in as user (admin) i get directed to the successful log in page  in the link go but  level 2 tabs are invisible or not rendered at all    I click on Home button in level1 navigation the tabs
    become rendered or viewable and i navigate normally
    I log out as admin the level 2 tabs becomes invisible again
    then I log in as (emp)  i get directed to the successful log in page and  level 2 tabs are still  invisible or not rendered
    I click on Home button in level1 navigation the only one tab the user emp authorized to it  gets rendered (appears)
    and its semi correct behavior because this is what I want him to see only
    my tries to find solution
    I tride to use
    #{securityContext.userInRole['division']}
    on the menu node item   I found same behavior level 2 tabs gets hidden till i click on home link at run time
    I tride to use #{securityContext.authenticated} to control item nods rending
    all tabs remains visible and i dont want that ain adition if user clicks on a tab of page he has no authority on it i recive server error
    I read 30.7 Creating a Login Page in the  Fusion Developer's Guide for Oracle Application Development Framework to finde about redirecting user
    and it is using the same as i did from adf tutorials
    I tried to make new navigation app on fast
    maybe i made incorrect change in any stage of my original app
    but I found same behavior
    I tried to set disabled property instead of rendered property the tabs are always rendered   but I got server error when I click on a tab which a user does not authorized
    So I doubt maybe problem in the El or the way I use to control rendering item node
    or there additional step to stop all  the tabs disappear after login
    I hope please some one Help or tell me what i have to read about in the developer guide  or interface developer guide or article on the web
    I'll be gratfule
    I know maybe it is small issue but help me please

    Hi,
    have a look at the sample that comes with this article: Oracle ADF: Security for Everyone It uses resource remissions to authorize panel tabs.
    One test to run is to print the outcome of the security evaluation (e.g. output text) to see what it returns.
    Frank

  • Anyone know why uploads contacts disappear from the iPhone 5? Half of my number is suddenly gone, and this happens over and over again? Kata-*******-stroff! Grateful for answers?

    IPHONE 5
    Anyone know why uploads contacts disappear from the iPhone 5?
    Half of my number is suddenly gone, and this happens over and over again?
    Kata-*******-stroff! Grateful for answers?

    do you sync your contacts with an application in your computer? or use iCloud?
    I can't tell you why the contacts disappear but you can get them back without much hassle by syncing through iTunes with your computer.
    do you regularly make backups?  if so, you can restore your iPhone using the backups and get your contacts back in your iPhone.
    It is strange that half of your contacts are gone over and over again.  Do you have Groups that are unchecked in your iPhone?  If so, the contacts in those groups will not appear in your contacts list but they are in your iPhone and be recovered by re-checking the group name.

Maybe you are looking for

  • Updating div  from two data sets with fading

    Hi, I am trying to do the following: I have a main area where I want to display an image (main image) of a product. This product has associated with it a few detail pictures of that product that are displayed next to the main image. I want to let the

  • Attach document in mail

    Hi, it appears I can't attach a document in outlook mail. Is there a solution?

  • Using a component as a rubber stamp

    I need to do something similar to what JTables, JLists, JComboBoxes, and JTrees do to render their individual elements. From what I understand, to save memory, they have one component which they then set whatever value on, use the component to draw,

  • Slow startup - can we pre-load AcroRd32.exe?

    Hi all, my users click on a PDF link and Acrobat 6.0 begins to launch within the IE browser. However, the launch slows down and sometimes fails when loading all the Acrobat plug-ins (api files). Now, when the user closes the browser, the AcroRd32.exe

  • Where on Mac HD are the Master Templates that i have created?

    I do the first time a new installation of mac hd without using Time Machine! now i miss my master templates folders i created on the old system. i try to search my time machine but where can i find the templates? Can you tell me the root? I want to c