daimajia / NumberProgressBar

A beautiful, slim Android ProgressBar.
MIT License
6.07k stars 1.4k forks source link

Caused by: java.lang.ClassCastException: com.daimajia.numberprogressbar.NumberProgressBar cannot be cast to android.widget.ProgressBar #32

Closed Jacko07 closed 7 years ago

Jacko07 commented 8 years ago

what's wrong?

pishguy commented 8 years ago

I think this error isn't for this librry, i have this error long time. please remove widget and create again. may be you should restart AndroidStudio.

i hope to help you

Dona278 commented 7 years ago

@Jacko07 It's not possible cast NumberProgressBar to ProgressBar because is an extended class of a generic View

public class NumberProgressBar extends View

In your activity you must use directly NumberProgressBar class to have access to their methods, otherwise you use a simple View class

daimajia commented 7 years ago

@Dona278 Thanks for your help on this thread.

@Jacko07 It has no relation with the android.widget.ProgressBar.