guys need help in reading objects from file… here’s my code.
// set a style name, so we can style rows and cells
table.setStyleName("iso3166");
// size
table.setWidth("100%");
table.setHeight("170px");
// selectable
table.setSelectable(true);
table.setMultiSelect(true);
table.setImmediate(true); // react at once when something is selected
// set column headers
table.addContainerProperty("Name", String.class, null);
//table.addContainerProperty("Size", String.class, null);
//table.addContainerProperty("Last Modified", String.class, null);
File directory = new File("C:/Users/Jet/Documents/error/uploads");
File fileList[] = directory.listFiles();
for(int i = 0; i < fileList.length; i++){
table.addItem( fileList[i]
.getName() );
System.out.println(fileList[i]
.getName());
}
addComponent(table);
the main problem is, I cant load the objects in my table. viewing output using System.out.print seems to work well w/ the objects, the only problem is loading them into the table.