Android adjust width of the ad-mob advertise to 70% of the screen width -
i want modify size of advertise of ad-mob 70% of screen shown in figure. tried it, through changing layout
layout
<linearlayout android:layout_width="fill_parent" android:layout_height="wrap_content" android:id="@+id/adlinear" android:orientation="horizontal"> <com.google.ads.adview android:id="@+id/adview" android:layout_width="0dip" android:layout_height="wrap_content" ads:adsize="banner" ads:adunitid="xxxxxxxxxxxxxx" ads:loadadoncreate="true" android:layout_weight="0.7" > </com.google.ads.adview> <linearlayout android:layout_width="0dip" android:layout_height="fill_parent" android:layout_weight="0.3" android:background="#00ff00" > <imageview android:id="@+id/imageview1" android:layout_width="fill_parent" android:layout_height="wrap_content" android:src="@drawable/logo" /> </linearlayout>
this xml works fine in large screen problem small screen. in small screen doesn't show , gives error.
02-05 19:21:59.265: e/ads(11210): not enough space show ad! wants: <480, 75>, has: <106, 636> 02-05 19:21:59.266: e/ads(11210): not enough space show ad! wants: <480, 75>, has: <336, 636> 02-05 19:21:59.267: e/ads(11210): not enough space show ad! wants: <480, 75>, has: <106, 636> 02-05 19:21:59.269: e/ads(11210): not enough space show ad! wants: <480, 75>, has: <336, 636>
is there possibility modify requirement <480, 75> of advertise??
try change ads:adsize="banner"
ads:adsize="smart_banner"
, in code
adview adview = new adview(this); adview.setadsize(adsize.smart_banner);
Comments
Post a Comment