i was wondering how would set up text boxes that store eg employee details i.e. Name, address, payroll number, date of joinning and also have buttons that i can add new employees and erase employees from the list, and a button that skips to the next employee Any help would be greatly appreciated
So what have you tried? Your question is wide open. It could be done a number of different ways.
Joined: May 25, 2001
well i have set up an office class which contains the name of the company and displays the out put. i have also set up an employee class which contains the names of the emploees and there details, under the method setEmployeeDetails(), and also there is a method in the employee class that displays the details of the employee. In the office class i have create three objects which corresponds too 3 different employees, and then data is passesd into the objects like name and payroll number etc using the display details method in the employee class. i hope i have not confused you i am quite new to this. thanx
Joined: May 17, 2001
The presentation could still be done a number of different ways.
1. With just text boxes and buttons. When the action event for the button is triggered, use the setText() of the text boxes to display the corresponding employee info. 2. JTable, display all emplyees and their detail within the JTable. 3. With a JCombo to hold the employee names and text fields to hold the detail. When an employee is selected fill the text fields. There are others as well. It depends on what you want. None of them are very difficult. The issue with all GUI options is getting a hang of all the layouts and how to get it to look just right. That takes practice and playing with all of the layouts and combining them to get what you want. I know this isn't very specific, but your question wasn't very specific.