|
-
February 4th, 1999, 06:25 AM
#1
Generation Registration number--- very urgent
i have a column in my Jtable in which registration number has to generate automatically.
this registration number should be system date concatenated to the serial number.
for example if am the fisrt candidate my registration number would be 104021999 and if am the second
candidate my regno would be 204021999. how can i accomplish this task????
thanks,
anand
-
July 9th, 1999, 07:31 PM
#2
Re: Generation Registration number--- very urgent
Hi,
You have to define a class that extends AbstractTableModel and you have a method in it setValueAt(i,j). i.e
public Object setValueAt(int i, int j){
return regno;
}
Here regno is the registration number in the format you require. To generate the regno you have to append the serial no.(or you can get the serial no. by adding one to getRowCount() method) to the System date and finally convert the resultant String to Object.
Hope this helps.
-Somu.
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
|
Click Here to Expand Forum to Full Width
|