A
asd
Hello all,
I have a question for my home work.
I have to do a java beans component for the homework.
I am planning to do something like a list box that lists contents of a
directory.
The problem is that, I want to encapsulate the GUI components in the
beans. I want to do it as follows.
class DirLister {
private JList listBox;
private JScrollpane scroll;
}
When I do it like this the listBox and its contents don't show up on the
screen.
Is there a way to make the GUI contents of a bean private and make them
visible on the screen?
Thank you so much for your time.
I have a question for my home work.
I have to do a java beans component for the homework.
I am planning to do something like a list box that lists contents of a
directory.
The problem is that, I want to encapsulate the GUI components in the
beans. I want to do it as follows.
class DirLister {
private JList listBox;
private JScrollpane scroll;
}
When I do it like this the listBox and its contents don't show up on the
screen.
Is there a way to make the GUI contents of a bean private and make them
visible on the screen?
Thank you so much for your time.