Dear Isomorphic Administrator,
We are working on a SmartGWT (version 6) ListGrid which has Image Data as one of its fields attached to VLayout, the Layout is added to a Window. We need to have a Vertical Scroll when the number of images are more than the visible area. This is very inconsistent in the sense some times the Vertical Scroll appears and sometimes not and also sometimes even when the datasource returns say 10 records not all records are rendered on the grid. please let us know your suggestions, snippet code for inspection as below:
VLayout layout = new VLayout(); Window window = new Window();
ListGrid grid = new ListGrid(); grid.setShowFilterEditor(false); grid.setDataSource(ds);
//fields int numberOfColumns= 3; String[] fieldsName = new String[numberOfColumns]; fieldsName[0] = "CREATED_DATE"; fieldsName[1] = "IMAGE_SELECTION"; fieldsName[2] = "IMAGE_VALUES";
String[] fieldsTitle = new String[numberOfColumns]; fieldsTitle[0] = "Created Date"; fieldsTitle[1] = "Image"; fieldsTitle[2] = "Attachment Type"; final ListGridField[] listGridField = new ListGridField[numberOfColumns];
for (int i = 0; i < numberOfColumns; i++) { listGridField[i] = new ListGridField(fieldsName[i], fieldsTitle[i]); } listGridField[1].setAlign(Alignment.CENTER);
grid.setFields(listGridField);
grid.setBodyOverflow(Overflow.SCROLL);
grid.setAutoFitData(Autofit.VERTICAL);
layout.addMember(grid); window.addItem(layout);
window.setCanDragResize(false);
window.show();
Specific Goal: Need to have a consistent vertical scroll bar and all the records to be rendered in the grid
Thank you!
We are working on a SmartGWT (version 6) ListGrid which has Image Data as one of its fields attached to VLayout, the Layout is added to a Window. We need to have a Vertical Scroll when the number of images are more than the visible area. This is very inconsistent in the sense some times the Vertical Scroll appears and sometimes not and also sometimes even when the datasource returns say 10 records not all records are rendered on the grid. please let us know your suggestions, snippet code for inspection as below:
VLayout layout = new VLayout(); Window window = new Window();
ListGrid grid = new ListGrid(); grid.setShowFilterEditor(false); grid.setDataSource(ds);
//fields int numberOfColumns= 3; String[] fieldsName = new String[numberOfColumns]; fieldsName[0] = "CREATED_DATE"; fieldsName[1] = "IMAGE_SELECTION"; fieldsName[2] = "IMAGE_VALUES";
String[] fieldsTitle = new String[numberOfColumns]; fieldsTitle[0] = "Created Date"; fieldsTitle[1] = "Image"; fieldsTitle[2] = "Attachment Type"; final ListGridField[] listGridField = new ListGridField[numberOfColumns];
for (int i = 0; i < numberOfColumns; i++) { listGridField[i] = new ListGridField(fieldsName[i], fieldsTitle[i]); } listGridField[1].setAlign(Alignment.CENTER);
grid.setFields(listGridField);
grid.setBodyOverflow(Overflow.SCROLL);
grid.setAutoFitData(Autofit.VERTICAL);
layout.addMember(grid); window.addItem(layout);
window.setCanDragResize(false);
window.show();
Specific Goal: Need to have a consistent vertical scroll bar and all the records to be rendered in the grid
Thank you!
Comment