material-range-bar icon indicating copy to clipboard operation
material-range-bar copied to clipboard

Binary XML file line #157: Error inflating class com.appyvet.materialrangebar.RangeBar

Open Rahulv2492 opened this issue 6 years ago • 10 comments

I am getting the error mention in title only for Android pie

Rahulv2492 avatar Dec 03 '18 13:12 Rahulv2492

Same issue for me as well on Kitkat (android version)

shammus1 avatar Jan 23 '19 11:01 shammus1

I solved it by using app:mrb_connectingLineColor instead of app:mrb_connectingLineColors

zdragnic avatar Feb 01 '19 15:02 zdragnic

I solved the issue by taking instead of in the arrays.xml file

irfancs avatar Sep 25 '19 14:09 irfancs

i have same problem when i use api 28. Please tell me how to fix

KimTH94 avatar Oct 30 '19 04:10 KimTH94

i am having same problem in api 29 please help to fix this

divyanshuArora avatar Dec 13 '19 08:12 divyanshuArora

Using 1.4.4 having the this issue. Anyone had a solution?

leowu4ever avatar Dec 24 '19 23:12 leowu4ever

The steps I took to solve this issue are as below:

  • update to 1.4.7 in build file
  • locate the xml files which have rangebar
  • attribute (tickcolor to tickdefaultcolor)
  • attribute (connectinglinecolor to connectinglinecolors), it should be assigned with an array.

If the above does not solve your issue, just do a careful comparison between your implementation and the examples.

It took me 2 hours to locate the bug since the error message (the title of this issue) didn't help. The log message at the end of logcat window which pointed to rangebar.java file helped me to locate the problematic attributes.

GOOD LUCK!

leowu4ever avatar Dec 25 '19 00:12 leowu4ever

In my case the crash is caused by app:mrb_tickColors, I put a regular resource color @color/transparent instead of an array. Took way too long to notice, and it happens only on Android Pie and above. Lollipop - Oreo is fine. Weird but hey at least it can be solved. I put my array like

<string-array name="transparent">
    <item>#00FFFFFF</item>
    <item>#00FFFFFF</item>
</string-array>

inside colors.xml in case anyone is wondering.

laurentiusandre avatar Sep 21 '20 11:09 laurentiusandre

I got the same issue...Do not resolve by applying all of the given suggestions using API level 30. I am stuck for 2 days. Please help me! will be obliged. I have completely followed the instructions on the link https://github.com/oli107/material-range-bar . Waiting for a suitable reply ASAP.

shero333 avatar Mar 12 '21 11:03 shero333

I solved it by using app:mrb_connectingLineColor instead of app:mrb_connectingLineColors

this does not work. What to do then?

shero333 avatar Mar 12 '21 11:03 shero333