Right now i m using Pinint Android SDK download it and integrated with my project but having an issue when i try to register for client this particular url has an error and not letting me to create client id. I added jar file in to project but still not working when i run project it crash with the following
06-26 17:31:11.173: E/AndroidRuntime(23743): FATAL EXCEPTION: main
06-26 17:31:11.173: E/AndroidRuntime(23743): java.lang.RuntimeException: Unable to start activity ComponentInfo{com.putitout.GREEGS/com.putitout.GREEGS.Menu.ProductDetail}: android.view.InflateException: Binary XML file line #358: Error inflating class com.pinterest.external.PinItButton
06-26 17:31:11.173: E/AndroidRuntime(23743): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2071)
06-26 17:31:11.173: E/AndroidRuntime(23743): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2096)
06-26 17:31:11.173: E/AndroidRuntime(23743): at android.app.ActivityThread.access$600(ActivityThread.java:138)
06-26 17:31:11.173: E/AndroidRuntime(23743): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1207)
06-26 17:31:11.173: E/AndroidRuntime(23743): at android.os.Handler.dispatchMessage(Handler.java:99)
06-26 17:31:11.173: E/AndroidRuntime(23743): at android.os.Looper.loop(Looper.java:213)
06-26 17:31:11.173: E/AndroidRuntime(23743): at android.app.ActivityThread.main(ActivityThread.java:4787)
06-26 17:31:11.173: E/AndroidRuntime(23743): at java.lang.reflect.Method.invokeNative(Native Method)
06-26 17:31:11.173: E/AndroidRuntime(23743): at java.lang.reflect.Method.invoke(Method.java:511)
06-26 17:31:11.173: E/AndroidRuntime(23743): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:789)
06-26 17:31:11.173: E/AndroidRuntime(23743): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:556)
06-26 17:31:11.173: E/AndroidRuntime(23743): at dalvik.system.NativeStart.main(Native Method)
06-26 17:31:11.173: E/AndroidRuntime(23743): Caused by: android.view.InflateException: Binary XML file line #358: Error inflating class com.pinterest.external.PinItButton
06-26 17:31:11.173: E/AndroidRuntime(23743): at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:698)
06-26 17:31:11.173: E/AndroidRuntime(23743): at android.view.LayoutInflater.rInflate(LayoutInflater.java:746)
06-26 17:31:11.173: E/AndroidRuntime(23743): at android.view.LayoutInflater.rInflate(LayoutInflater.java:749)
06-26 17:31:11.173: E/AndroidRuntime(23743): at android.view.LayoutInflater.rInflate(LayoutInflater.java:749)
06-26 17:31:11.173: E/AndroidRuntime(23743): at android.view.LayoutInflater.inflate(LayoutInflater.java:489)
06-26 17:31:11.173: E/AndroidRuntime(23743): at android.view.LayoutInflater.inflate(LayoutInflater.java:396)
06-26 17:31:11.173: E/AndroidRuntime(23743): at android.view.LayoutInflater.inflate(LayoutInflater.java:352)
06-26 17:31:11.173: E/AndroidRuntime(23743): at com.android.internal.policy.impl.PhoneWindow.setContentView(PhoneWindow.java:262)
06-26 17:31:11.173: E/AndroidRuntime(23743): at android.app.Activity.setContentView(Activity.java:1867)
06-26 17:31:11.173: E/AndroidRuntime(23743): at com.putitout.GREEGS.Menu.ProductDetail.onCreate(ProductDetail.java:82)
06-26 17:31:11.173: E/AndroidRuntime(23743): at android.app.Activity.performCreate(Activity.java:5008)
06-26 17:31:11.173: E/AndroidRuntime(23743): at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1079)
06-26 17:31:11.173: E/AndroidRuntime(23743): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2035)
06-26 17:31:11.173: E/AndroidRuntime(23743): ... 11 more
06-26 17:31:11.173: E/AndroidRuntime(23743): Caused by: java.lang.ClassNotFoundException: com.pinterest.external.PinItButton
06-26 17:31:11.173: E/AndroidRuntime(23743): at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:61)
06-26 17:31:11.173: E/AndroidRuntime(23743): at java.lang.ClassLoader.loadClass(ClassLoader.java:501)
06-26 17:31:11.173: E/AndroidRuntime(23743): at java.lang.ClassLoader.loadClass(ClassLoader.java:461)
06-26 17:31:11.173: E/AndroidRuntime(23743): at android.view.LayoutInflater.createView(LayoutInflater.java:552)
06-26 17:31:11.173: E/AndroidRuntime(23743): at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:687)
06-26 17:31:11.173: E/AndroidRuntime(23743): ... 23 more
Need help on this Thank you
From the Log its clear that the exception is caused while inflating the widget Pinit Button. I just opened the jar file using my archieve manager and found that "PinItButton" is not located at the path
<com.pinterest.external.PinItButton
as documented in sdk.
The actual path is
<com.pinterest.pinit.PinItButton
Substitute the above path for your Pinit button in XML and the issue will be resolved.
In order to solve this please remove the button code from Xml, rather create the button using Java. Then this problem will be solved.
For Example
RelativeLayout view = (RelativeLayout) findViewById(R.id.v);
PinItButton pinIt = new PinItButton(this);
view.addView(pinIt);
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With