Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8277279
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 8, 20262026-06-08T08:38:41+00:00 2026-06-08T08:38:41+00:00

I am working on Custom Progress Dialog . I’ve set its style like done

  • 0

I am working on Custom Progress Dialog. I’ve set its style like done in this SO question Positionning the spinning wheel in a custom progress dialog My progress dialog is showing no animation at all. When I changed the background to black then it was only showing a black box. I want my progress dialog to animate.

In activity I am doing something like this

 public MyProgressDialog(Context context) {
        super(context, R.style.NewDialog);
    }

and the NewDialog is as:

<style name="NewDialog" parent="@android:style/Theme.Dialog">

    <item name="android:windowFrame">@null</item>
    <item name="android:windowBackground">@android:color/transparent</item>
    <item name="android:windowIsFloating">true</item>
    <item name="android:windowContentOverlay">@null</item>
    <item name="android:windowTitleStyle">@null</item>
    <item name="android:windowAnimationStyle">@android:style/Animation.Dialog</item>
    <item name="android:windowSoftInputMode">stateUnspecified|adjustPan</item>
    <item name="android:backgroundDimEnabled">true</item>
    <item name="android:width">50dip</item>
    <item name="android:height">50dip</item>
    <item name="android:background">@android:color/transparent</item>

</style>

Any help is appreciated in advance

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-08T08:38:43+00:00Added an answer on June 8, 2026 at 8:38 am
    import android.app.ProgressDialog;
    import android.content.Context;
    import android.view.animation.Animation;
    
    public class MyProgressDialog extends ProgressDialog {
    
        public MyProgressDialog(Context context) {
            super(context,R.style.NewDialog);
    
            // TODO Auto-generated constructor stub
        }
    
    }
    

    //RESOURCE STYLE FILE res->values->mydialog.xml

    <?xml version="1.0" encoding="utf-8"?>
    <resources>
       <style name="NewDialog" parent="@android:style/Theme.Dialog">
    
        <item name="android:windowFrame">@null</item>
        <item name="android:windowBackground">@android:color/transparent</item>
        <item name="android:windowIsFloating">true</item>
        <item name="android:windowContentOverlay">@null</item>
        <item name="android:windowTitleStyle">@null</item>
        <item name="android:colorBackground">#ffffff</item>
        <item name="android:windowAnimationStyle">@android:style/Animation.Dialog</item>
        <item name="android:windowSoftInputMode">stateUnspecified|adjustPan</item>
        <item name="android:backgroundDimEnabled">true</item>
        <item name="android:width">600dip</item>
        <item name="android:height">100dip</item>
         <item name="android:textColor">#FF0000</item>
    
    </style>
    </resources>
    

    //AND USE THIS CODE ANYWHERE IN YOUR APPLICATION TO GET CUSTOM PROGRESS DIALOG

    MyProgressDialog pd = new MyProgressDialog(YouActivity.this);
    pd.setMessage("Loading. Please wait...");
    pd.show();
    

    Well there isn’t any difference in your code and mine as I have run your code just to test whether you are experiencing any problem or not but still I am posting for you so that you can sought out the problem.

    Thanks 🙂

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a working custom UserNamePasswordValidator that calls into my Oracle DB. This class
I have a nicely working custom CursorAdapter with customized ListView. This view allows the
I'm working up a custom Xcode template, and I'd like to change the way
When i'm in onActivityResult and i try to show a custom progress dialog, The
I am working on a custom debug view in an Eclipse plugin. In this
I'm working a custom workflow activity and would like to allow the user to
I'm trying to create a custom download app. Its all working except for the
will this code when working show custom pins and logos or just 1 pin
I'm working on a custom mark-release style memory allocator for the D programming language
I have successfully created one custom dialog box. Dialog box is working good. I

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.