0

I want to custom my ProgressDialog,I have made

setIndeterminateDrawable(context.getResources().getDrawable(R.drawable.processbar_style)),

this is R.drawable.processbar_style:

<?xml version="1.0" encoding="utf-8"?>
<rotate xmlns:android="http://schemas.android.com/apk/res/android"
    android:drawable="@drawable/processbar"
    android:pivotX="50%"
    android:pivotY="50%" 
 />
VendettaDroid
  • 3,131
  • 2
  • 28
  • 41
oldfox3721
  • 101
  • 1
  • 1
  • 9
  • Take a look at this http://stackoverflow.com/a/7304685/1143977 – VendettaDroid Sep 05 '12 at 03:33
  • When I Using ProgressBar in a View,It can word very well. But,when I do the same things in ProgressDialog,the drawable is not rotated(animated). So I think it is can not be explained。 – oldfox3721 Sep 05 '12 at 03:48
  • I have read the answer of url which you give me .I want by rotate to show my ProgressBar ,not by anmiated. because, I just a one .png, can you tell me a way to reach target, I thanks u very much.Ps.english is not my mother tongue, please forgive me so poor description。Thank u over and over。 – oldfox3721 Sep 05 '12 at 06:09

1 Answers1

0

use it programatically like this:

define and start your progressdialog wherever you are starting your work for which you wanna show progress

    pd=new ProgressDialog(this);
    pd=ProgressDialog.show(*Your_Activity*.this,"","Please wait");

and just end it when the work is completed.

    pd.dismiss();

it gives me animated progress display in a progress dialog box.

nam_ph
  • 233
  • 1
  • 3
  • 12