Display EditField in ListField BlackBerry

In my application, I need to display a list of items with a price in EditField . How to add EditField to the list?

For ListField , I use this code

 public void drawListRow(ListField listField, Graphics graphics, int index, int y, int width) { this.listField=listField; String text=(String) get(listField, index); if(holder[index]==null) { holder[index]=placeholder; } graphics.setColor(rgb); graphics.setFont(Utility.getBigFont(DConfig.getFSize()+4)); graphics.drawBitmap(3,y+7,placeholder.getWidth(), placeholder.getHeight(),holder[index], 0, 0); graphics.drawText(text,100,y+15); graphics.drawText("Price:",100,y+30); graphics.drawText(CartScreen.price[index],100,y+45); graphics.drawLine(0, y+74, DConfig.disWidth, y+74); } 

How to add an edit field to a list of lines

+1
source share
1 answer

You cannot place the EditField there. It is best to use only the VerticalFieldManager and the LabelFields / EditFields stack. It will still scroll, just won't be a ListField.

+2
source

All Articles