Skip to content

Instantly share code, notes, and snippets.

View fancellu's full-sized avatar

Dino Fancellu fancellu

View GitHub Profile
@canthony
canthony / CreateContainer.java
Created June 6, 2012 08:11
Reading an excel spreadsheet and creating a Vaadin container : Not complete
public class CreateContainer {
public static void main(String[] args) throws IOException {
FileInputStream in = new FileInputStream("C:/temp/SampleData.xls");
POIFSFileSystem fileSystem = new POIFSFileSystem(in);
HSSFWorkbook workBook = new HSSFWorkbook(fileSystem);
HSSFSheet sheet = workBook.getSheetAt(0);
List<String> propertyNames = Collections.emptyList();
IndexedContainer c = new IndexedContainer();
for (Row row : sheet) {
int rowIndex = row.getRowNum();