Solved

Using setEnabled on GUI components inside a JTabbedPane

Posted on 2009-04-06
3
441 Views
Last Modified: 2013-12-14
I am using setEnabled(false) on the tabbed pane. When a certain condition is met, the setEnabled becomes true. I have panels inside the tabbed pane which I would like to disable until a condition is met. I have tried setEnabled(false) on them from various places and the constructor itself however no success.
0
Comment
Question by:namsu55
  • 2
3 Comments
 
LVL 24

Expert Comment

by:sciuriware
ID: 24083998
Try .setVisible(false);

;JOOP!
0
 

Author Comment

by:namsu55
ID: 24084114
That removes the whole panel from the GUI, I want is visible but disabled for use (Greyed).
0
 
LVL 24

Accepted Solution

by:
sciuriware earned 500 total points
ID: 24084922
I think that is not possible with this kind of components.
What you can do is swap the component with a label or such with the same size
and a grey background.
This swapping can be done by setting one visible and the other one to invisible.

;JOOP!
0

Featured Post

ScreenConnect 6.0 Free Trial

Check out the updates in one game-changing release, ScreenConnect 6.0, based on partner feedback. New features include a redesigned UI that improves session organization and overall user experience. See the enhancements for yourself!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
java jdbc batch example 8 32
servlet example issue 6 38
jboss wildfly 10.1 10 87
going to wrong jsp page 2 20
Programmer's Notepad is, one of the best free text editing tools available, simply because the developers appear to have second-guessed every weird problem or issue a programmer is likely to run into. One of these problems is selecting and deleti…
Java functions are among the best things for programmers to work with as Java sites can be very easy to read and prepare. Java especially simplifies many processes in the coding industry as it helps integrate many forms of technology and different d…
Viewers will learn about basic arrays, how to declare them, and how to use them. Introduction and definition: Declare an array and cover the syntax of declaring them: Initialize every index in the created array: Example/Features of a basic arr…
This video teaches viewers about errors in exception handling.

770 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question