Issue With Using Progressbar.setprogressdrawable
Using setProgressDrawable for a ProgressBar with custom colors does not work in a correct way for us. We use progressbars in the rows of a ListView, but the progress is only displa
Solution 1:
private void updateProgressbar(View view, Cursor cursor) {
ProgressBar progressBar = (ProgressBar) view
.findViewById(R.id.progressbarHorizontal);
progressBar.setProgressDrawable(view.getResources().getDrawable(
R.drawable.greenprogress));
> progressBar.setProgress(1); "Add this statement before setting the progress.."
progressBar.setMax(cursor.getInt(cursor.getColumnIndex("numberpages")));
progressBar.setProgress(cursor.getInt(cursor
.getColumnIndex("currentpage")));
}
Post a Comment for "Issue With Using Progressbar.setprogressdrawable"