equipmentAddonsDs.clear();
if (equipment.getEquipmentAddons().size() > 0) {
for (EquipmentAddons equipmentAddon : equipment.getEquipmentAddons()) {
equipmentAddonsDs.addItem(equipmentAddon);
}
}
When I run the code above, the first iteration shows 0 items in the equipmentAddonsDs. On the second iteration, there are 51. Then, 52, 53, and so on. There are always an extra 50 items after the first .addItem(). Can you think of a reason why adding 1 item to a ds would add an extra 50?
No. Could you give us more details about the datasource type and how you count its size? Also, you could debug your code and find out what it really contains.
passing the CollectionDatasource in as a param. The window has a GroupDataSource, so I’m clearing it, then copying the items over from the CollectionDataSource that was passed in. I can’t get that to work!
So, I’ve tried passing in the Equipment item instead, but that is causing the error where it’s adding tons of data when the first item is copied over.
All I need to do is open a table in a new window, because the table doesn’t fit on the screen. It sounds so easy, but I just can’t get it. How would you do it?