Article View: borland.public.jbuilder.java.swing
Article #1777Re: Jpanel and Components
From: Rich Wilkman
Date: Sun, 20 Jul 2003 21:50
Date: Sun, 20 Jul 2003 21:50
18 lines
1511 bytes
1511 bytes
Set the name property on the component and check that while iterating is one way. If you want to make a change to a particular type of component you could just check type. -Rich lredmond wrote: >I have a panel with serveral buttons and labels. When a particular event >occurs I need to set the caption on each button, >i used jpanel .getComponents() to retrieve a list of all the components on >the panel. How can I check for a particular component... > >Component[] comp = panel.getComponents(); > > > >
Technical Details
Message-ID:
<3F1B0E9C.5020002@formlessvoid.com>Path:
arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-04!sn-xit-01!sn-xit-08!supernews.com!newsfeed.wirehub.nl!news.kweb.on.ca!newsgroups.borland.com!not-for-mailReferences:
<3f1b0167$1@newsgroups.borland.com>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 111d45,a1a3f8c21ef03b96 X-Google-Attributes: gid111d45,public X-Google-ArrivalTime: 2003-07-20 15:02:40 PST Message-ID: <3F1B0E9C.5020002@formlessvoid.com> Date: Sun, 20 Jul 2003 14:50:20 -0700 From: Rich Wilkman <richw@formlessvoid.com> User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.0.2) Gecko/20021120 Netscape/7.01 X-Accept-Language: en-us, en MIME-Version: 1.0 Newsgroups: borland.public.jbuilder.java.swing Subject: Re: Jpanel and Components References: <3f1b0167$1@newsgroups.borland.com> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit NNTP-Posting-Host: 63.249.85.97 X-Trace: newsgroups.borland.com 1058737811 63.249.85.97 (20 Jul 2003 14:50:11 -0700) Lines: 19 Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-04!sn-xit-01!sn-xit-08!supernews.com!newsfeed.wirehub.nl!news.kweb.on.ca!newsgroups.borland.com!not-for-mail