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.

Solutions on the web

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

4 times, 8 months ago
Samebug visitor profile picture
Unknown user
Once, 1 year ago
3 times, 2 months ago
8 times, 1 year ago
6 times, 1 year ago
186 more bugmates

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