hi,

I need to list a all the files one by one in a JTable...I am sending you
the code..below..it is displaying only one row with the first 4 files, how
do I get the list of other files into the other rows...pls let me know...

createTableData();
createTableHeadings();
JTable tblDisplay ;

tblDisplay = new JTable(tableData, tableHeadings);
tblDisplay.setRowHeight(20);

private void createTableData()
{

FileTransferControl ftc = new FileTransferControl();
String dirName = "D:/Msat/config/";
fileNames= ftc.listDirectory(dirName);
Vector row1 = new Vector();
Vector row2 = new Vector();
Vector row3 = new Vector();
Vector row4 = new Vector();
Vector row5 = new Vector();

for(int i=0;i<fileNames.length;i++)
{
System.out.println(fileNames[i]);
row1.addElement(fileNames[i]);

// I dont know the logic to implement here...pls help


}

tableData.addElement(row1);
tableData.addElement(row2);
tableData.addElement(row3);
tableData.addElement(row4);







}

private void createTableHeadings()
{
tableHeadings.addElement("Filename");
tableHeadings.addElement("OAM");
tableHeadings.addElement("Telepath");
tableHeadings.addElement("MSAT");

}



Satish