File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Swing / AWT / SWT and the fly likes JTable dialog keeps previously entered values Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of REST with Spring (video course) this week in the Spring forum!
JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "JTable dialog keeps previously entered values" Watch "JTable dialog keeps previously entered values" New topic

JTable dialog keeps previously entered values

Carl S.

Joined: Nov 07, 2006
Posts: 1

This is my first post here so please be patient since I'm not sure what code to post and what not to, and thanks for your help before hand!

The problem is:

I have a JTable based dialog. It has rows (x many) and colums (4) set by an XMLTableModel. Each row represents a file on which the user needs to fill in certain values for such as, etc (the columns). The files are in col 4. The other cells are editable. This works fine and the output too, BUT if the user wants to do the same again, SOME data is left in the dialogs table.

How do I make sure the table is entirelly clean before next session and what code would any of you need to see to help?


Michael Dunn
Ranch Hand

Joined: Jun 09, 2003
Posts: 4632
do you create/dispose the dialog initially, then for the next session use

if so, try re-creating the dialog for each session.
subject: JTable dialog keeps previously entered values
It's not a secret anymore!