In my xml i have write this code and i have use the publisher id test :
<LinearLayout
android:id="@+id/LinearLayout2"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical" >
<Button
android:id="@+id/b1"
android:layout_width="match_parent"
android:layout_height="100dp"
android:background="@drawable/ic_launcher10" />
<com.adsdk.sdk.banner.AdView
android:id="@+id/mobFoxView"
android:layout_width="300dp"
android:background="#000000"
android:layout_height="50dp"
request_url="http://my.mobfox.com/request.php"
publisherId="fe96717d9875b9da4339ea5367eff1ec"
location="true"
animation="true"
/>
</LinearLayout>
but at the same time I get this message:
The following classes could not be instantiated:
- com.adsdk.sdk.banner.AdView (Open Class, Show Error Log)
See the Error Log (Window > Show View) for more details.
Tip: Use View.isInEditMode() in your custom views to skip code when shown in Eclipse
java.lang.NullPointerException
at com.adsdk.sdk.banner.AdView.<init>(AdView.java:95)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0( at sun.reflect.NativeConstructorAccessorImpl.newInstance( at sun.reflect.DelegatingConstructorAccessorImpl.newInstance( at java.lang.reflect.Constructor.newInstance( at com.android.ide.eclipse.adt.internal.editors.layout.ProjectCallback.instantiateClass(ProjectCallback.java:422)
at com.android.ide.eclipse.adt.internal.editors.layout.ProjectCallback.loadView(ProjectCallback.java:179)
at android.view.BridgeInflater.loadCustomView(BridgeInflater.java:207)
at android.view.BridgeInflater.createViewFromTag(BridgeInflater.java:135)
at android.view.LayoutInflater.rInflate_Original(LayoutInflater.java:746)
at android.view.LayoutInflater_Delegate.rInflate(LayoutInflater_Delegate.java:64)
at android.view.LayoutInflater.rInflate(LayoutInflater.java:718)
at android.view.LayoutInflater.rInflate_Original(LayoutInflater.java:749)
at android.view.LayoutInflater_Delegate.rInflate(LayoutInflater_Delegate.java:64)
at android.view.LayoutInflater.rInflate(LayoutInflater.java:718)
at android.view.LayoutInflater.inflate(LayoutInflater.java:489)
at android.view.LayoutInflater.inflate(LayoutInflater.java:372)
when I start the application it crashes. i have add in libs the AdSdk_4.1.6.jar and the mobfoxsdk-1.5.jar. i have add in manifest this permission
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />
<uses-permission android:name="android.permission.READ_PHONE_STATE"/>
and this: <activity android:name="com.mobfox.sdk.InAppWebView"/>
What can I do to successfully implement the banner? thanks in advance