Steps that I have taken are listed below...
1) I have downloaded "admob for flash air (admob_all_in_o ne6.6.7.ane) from this link http://fuji.h1de.net/browse.php?u=Oi...zLw%3D%3D&b=13
2) I added this native extension to my flash cs6 project via advanced actionscript 3 settings -> library path tab.
3) Set my flash target to the air 4.0.01390 for android.
4) I wrote a small class to inialize add....
5) In my main.as class I am calling the displayadd() method like this...
6) I have added this code to myappname-app.xml
7) published app to my new samsung that uses andriod version 4.2.2
8) no ads display, my app just crashes and de-activates when i call
have i missed something ?
1) I have downloaded "admob for flash air (admob_all_in_o ne6.6.7.ane) from this link http://fuji.h1de.net/browse.php?u=Oi...zLw%3D%3D&b=13
2) I added this native extension to my flash cs6 project via advanced actionscript 3 settings -> library path tab.
3) Set my flash target to the air 4.0.01390 for android.
4) I wrote a small class to inialize add....
Code:
package
{
import flash.display.Sprite;
import so.cuo.platform.admob.Admob;
import so.cuo.platform.admob.AdmobEvent;
public class Interstitial extends Sprite
{
var admob:Admob= Admob.getInstance();
public function Interstitial()
{
super();
}
public function displayAdd():void
{
if(admob.supportDevice)
{
// i have replaced setKeys with my admob ad unit id "ca-app-pub-xxxxxxxxxxx/xxxxxxxxxxx"
admob.setKeys("a152834c8723912");
admob.addEventListener(AdmobEvent.onInterstitialReceive,onAdReceived);
admob.cacheInterstitial();
}
}
protected function onAdReceived(event:AdmobEvent):void
{
if(event.type==AdmobEvent.onInterstitialReceive){
admob.showInterstitial();
}
}
}
Code:
var showAdd:Interstitial = new Interstitial();
showAdd.displayAdd();
Code:
<android>
<manifestAdditions>
<![CDATA[<manifest>
<uses-permission android:name="android.permission.INTERNET"/>
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE"/>
<uses-permission android:name="android.permission.ACCESS_WIFI_STATE"/>
<application>
<activity android:name="com.google.ads.AdActivity" android:configChanges="keyboard|keyboardHidden|orientation|screenLayout|uiMode|screenSize|smallestScreenSize"/>
</application>
</manifest>]]>
</manifestAdditions>
</android>
<extensions>
<extensionID>so.cuo.platform.admob</extensionID>
</extensions>
8) no ads display, my app just crashes and de-activates when i call
Code:
var showAdd:Interstitial = new Interstitial();
showAdd.displayAdd();