How to make custom indeterminate ProgressBar in Android or how to change ProgressBar style or color

Hi,

Here i want to show you how easily make your own Android ProgressBar style or how to change ProgressBar color.

It is very easy! Also below you can download source code of Android project.

Below you can see the screenShot with ProgressBar

Indeterminate ProgressBar style

To do this you need:

  • Create the image for this ProgressBar in any graphical editor.
  • Create animation drawable with content:

Where @drawable/image_for_rotation is resource of your progressBar image.
  • Select android:indeterminateDrawable for ProgressBar witget.

Enjoy! :)

Here you can download Sample project with custom Android ProgressBar.

Download it from github

19 thoughts on “How to make custom indeterminate ProgressBar in Android or how to change ProgressBar style or color

  • By Anees - Reply

    Good one !!!! Helped to create a smooth custom progress bar.

  • By bos - Reply

    brilliant! thanx

  • By Igor - Reply

    You’re welcome, guys

  • By Jesse - Reply

    Great!

  • By Atul bhardwaj - Reply

    Great code

  • By Deepthi G - Reply

    Great post!! :) Keep up the great work!! May be you can visit my humble blog too..

    Regards
    Deepthi G

  • By Ramesh - Reply

    Nice! Its really superb trick!

  • By Greg - Reply

    great help for me. Thanks a lot!!

  • By Vish - Reply

    Thanks a lot. You saved my time & it worked nicely.

  • By raheel - Reply

    hi , gr8 tutorial,
    i have a question, how can i increase the speed of the rotation

  • By Rafsan - Reply

    How can i stop this progressBer. Is there any process to set the duration?

  • By Igor - Reply

    Hello, Rafsan
    The intermediate progress bar cannot be stopped. You can make it invisible. I’ll doing this task in this way.

  • By manel - Reply

    help me please for develpped android

  • By Dude - Reply

    nice bro

  • By prasad - Reply

    how to make a transparent webview behind a gridview.

  • By Igor - Reply

    Hello prasad,
    I’ve posted info special for you :)
    Hope, It help you http://www.hrupin.com/2012/08/how-to-make-a-transparent-webview-in-android

  • By Igor - Reply

    Hello manel,
    What help do you need?

  • By prasad - Reply

    thanks bro for ur reply…..i will tell were iam stuck..i have a home page with two buttons and and weview showing google.com..when i click on one button one gridview should come…the grid view should be above the webview we should see both the web view and gridview …and if i click the same button gridview should go and webview should be seen how this transparency can be achieved plz help..iam stuck here

  • By prasad - Reply

    bro can this progress bar be used while switching between webpages in application in same layout………..

Leave a Reply

Your email address will not be published. Required fields are marked *


nine + 4 =

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code class="" title="" data-url=""> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> <pre class="" title="" data-url=""> <span class="" title="" data-url="">