🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.jbuilder.java.api
Article #2727

Re: Frame -> Panel Problem

#2727
From: Atle Wilhelmsen
Date: Tue, 11 Apr 2000 00:00
40 lines
1833 bytes
You need to call the method validate on the panel object.
This method ensures that the given component has a valid layout.

- Atle

Jochen Vastmans <jochen.vastmans@student.kuleuven.ac.be> wrote in message
news:955383546.718837@marvin...
> Hello,
>
> I have some problems with panels in a frame.
> This is what I want to do...
>
> In a Frame I have 2 panels. In the first panel
> are four buttons. What I want to do is, when you
> click one of the four buttons, some components are
> added to the second panel.
>
> What I tried is, I just added a component in the
> second panel, but that doesn't update the whole thing
> (nothing happens), I tried to put the following lines
> which are set in the Frame-constructor in a method,
> and by adding components just call that method.
> But still it doesn't do anything
>
> protected void method(){
> setLayout(new BorderLayout());
> add(panel1,BorderLayout.NORTH);
> add(panel2,BorderLayout.CENTER);
> }
>
> Can someone give me a solution?
>
> Best Regards,
>
> Jochen Vastmans
>
> e-mail: jochen.vastmans@student.kuleuven.ac.be
>
>
>
Technical Details
Message-ID: <aEAI4.2651$r6.245292@juliett.dax.net>
Path: arc1-ca.pugleaf.net!unknown!not-for-mail
References: <955383546.718837@marvin>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 1089d0,28ed0cb65287a8a
X-Google-Attributes: gid1089d0,public
From: "Atle Wilhelmsen" <atle.wilhelmsen@tietoenator.com>
Subject: Re: Frame -> Panel Problem
Date: 2000/04/11
Message-ID: <aEAI4.2651$r6.245292@juliett.dax.net>
X-Deja-AN: 609501457
References: <955383546.718837@marvin>
X-Priority: 3
X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2014.211
X-Complaints-To: abuse@tele2.no
X-Trace: juliett.dax.net 955438726 193.216.57.66 (Tue, 11 Apr 2000 09:38:46 MET DST)
Organization: Tele2 Norway AS Public Access
X-MSMail-Priority: Normal
NNTP-Posting-Date: Tue, 11 Apr 2000 09:38:46 MET DST
Newsgroups: borland.public.jbuilder.java.api