2
我想在表格單元格中添加一個組合框來提供拖放選項LWUIT。如何在使用LWUIT - J2ME的表格單元格中添加組合框?
我已經使用這個選項吧..
private String strCmbBox[] = { "1", "2", "3", "4" };
ComboBox comboRdoBox = new ComboBox(strCmbBox);
comboRdoBox.setListCellRenderer(new comboBoxRenderer());
TableModel model = new DefaultTableModel(new String[] { "Col 1",
"Col 2", "Col 3" }, new Object[][] {
{"Row 1",new DefaultTableModel(new String[] { "1" },
new Object[][] { { comboRdoBox }, { "lbl" } }),
"Row X" }, { "Row 2", "Row B", "Row Y" },
{ "Row 3", "Row C", "Row Z" },
{ "Row 4", "Row D", "Row K" }, });
Table table = new Table(model);
table.initComponent();
f.addComponent(table);
f.show();
但它返回的地址n在小區內的所有屬性值;而顯示組合框在細胞 ...
任何一個可以幫助我解決這個... ???