-
Checking to see if a button is visible
I need to know the line of code required to check to see if a button is visible at the time. I want the program to check if the button is visible, and if it is visible, hide it. If it's not visible, show it.
-
try something like this
if(button.isVisible()){button.setVisible(False)}
else{button.setVisible(true)}
the isVisible is inherited from Component and setVisible is inherited from JComponent.
not sure if this will work though as I'm just learning too, but maybe will help
Similar Threads
-
By James Graham in forum .NET
Replies: 4
Last Post: 10-23-2011, 02:47 PM
-
By vipin_pc in forum VB Classic
Replies: 8
Last Post: 11-17-2006, 02:22 PM
-
By 2eXtreme in forum Java
Replies: 0
Last Post: 04-05-2006, 07:38 AM
-
By DrunkinP in forum Java
Replies: 0
Last Post: 03-31-2005, 09:36 AM
-
Replies: 0
Last Post: 11-20-2002, 11:16 PM
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
Forum Rules
|
Top DevX Stories
Easy Web Services with SQL Server 2005 HTTP Endpoints
JavaOne 2005: Java Platform Roadmap Focuses on Ease of Development, Sun Focuses on the "Free" in F.O.S.S.
Wed Yourself to UML with the Power of Associations
Microsoft to Add AJAX Capabilities to ASP.NET
IBM's Cloudscape Versus MySQL
|
Bookmarks