views:

28

answers:

0

Hi, I'd be very thankful if someone would give me a hint on how to display a static ProgressBar (or any widget that displays a percentage in a bar format) within a ListView in an Android app.

Here's my code:

startManagingCursor(c);
String[] from = { "category", "amountPercentage" };
int[] to = { R.id.second_line, R.id.third_line_bar };
SimpleCursorAdapter adapter = new SimpleCursorAdapter(this, R.layout.item_list, c, from, to);
setListAdapter(adapter);

Where "amountPercentage" was populated with double values between 0 to 1 to represents 0% to 100%.

Big thanks.