progress bar - android how to change the progressbar color programatically -
how can change progressbar color within app. have set in xml value gets within preset thresholds need change color of bar alert user. buttons can set example below. there way with progressbar?
b.setbackgrounddrawable(c.getresources().getdrawable(r.drawable.button2)); b.getbackground().setcolorfilter( users.colorbtnback, porterduff.mode.multiply);
i posted tip comment on other question, see http://colintmiller.com/2010/10/07/how-to-add-text-over-a-progress-bar-on-android/
scroll down "bonus tip", discusses changing color. guess want predefined set of colors, switch between using setprogressdrawable()
Comments
Post a Comment