java.lang.NumberFormatException: Invalid int: "res/drawable-xhdpi-v4/ic_action_share.png"

Searched on Google with the first line of a JAVA stack trace?

We can recommend more relevant solutions and speed up debugging when you paste your entire stack trace with the exception message. Try a sample exception.

Recommended solutions based on your search

Samebug tips

,

You try to parse a String that contains non-numeric characters to an int. The string must contain decimal characters only, optionally beginning with a + or - sign.

,

Can occur when you try to convert a String to a numeric value but the String is not well formatted for the conversion.

Solutions on the web

via Stack Overflow by Maksim Diakonov
, 2 years ago
via Stack Overflow by Siddhpura Amit
, 2 years ago
Invalid int: "res/drawable/playing_progress_bar_bg.xml"
via Stack Overflow by JuniorIncanter
, 2 years ago
Invalid int: "res/drawable/dummy_background_image.png"
via Stack Overflow by embo
, 2 years ago
via Stack Overflow by Harsha M V
, 2 years ago
java.lang.NumberFormatException: Invalid int: "res/drawable-xhdpi-v4/ic_action_share.png"
at java.lang.Integer.invalidInt(Integer.java:138)
at java.lang.Integer.parse(Integer.java:375)
at java.lang.Integer.parseInt(Integer.java:366)
at com.android.internal.util.XmlUtils.convertValueToInt(XmlUtils.java:123)
at android.content.res.TypedArray.getInt(TypedArray.java:254)
at android.view.View.(View.java:3561)
at android.view.ViewGroup.(ViewGroup.java:432)
at com.example.trace.CustomShareActionProvider.ActivityChooserView.(Unknown Source)
at com.example.trace.CustomShareActionProvider.ActivityChooserView.(Unknown Source)
at com.example.trace.CustomShareActionProvider.ActivityChooserView.(Unknown Source)
at com.example.trace.CustomShareActionProvider.ShareActionProvider.onCreateActionView(Unknown Source)
at android.support.v4.view.y.a(Unknown Source)
at com.example.trace.p.a(Unknown Source)
at android.support.v4.app.Fragment.b(Unknown Source)
at android.support.v4.app.n.a(Unknown Source)
at android.support.v7.a.g.a(Unknown Source)
at android.support.v7.a.m.a(Unknown Source)
at android.support.v7.a.g.onCreatePanelMenu(Unknown Source)
at android.support.v7.a.n.onCreatePanelMenu(Unknown Source)
at com.android.internal.policy.impl.PhoneWindow.preparePanel(PhoneWindow.java:445)

Users with the same issue

Once, 1 month ago
Once, 3 months ago
852 times, 3 months ago
23 times, 4 months ago
3 times, 4 months ago

Write tip

Know the solutions? Share your knowledge to help other developers to debug faster.