# Not a compile-time constant (external api)

**URL:** https://forum.kirupa.com/t/not-a-compile-time-constant-external-api/332432
**Category:** flash
**Created:** [June 6, 2014, 4:00pm UTC](https://forum.kirupa.com/t/not-a-compile-time-constant-external-api/332432 "2014-06-06T16:00:38Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![nightkarnation](https://avatars.discourse-cdn.com/v4/letter/n/a5b964/32.png) [@nightkarnation](https://forum.kirupa.com/u/nightkarnation)
#### Post date: [June 6, 2014, 4:00pm UTC](https://forum.kirupa.com/t/not-a-compile-time-constant-external-api/332432/1 "2014-06-06T16:00:38Z")

</div>

Hey guys,

I have an error trying to implement an api from AppNext…  
Here’s the very simple code:

```auto

public class AppNext extends MovieClip
    {
        var appnextExtension:AppnextASExtension = null;

        public function AppNext()
        {
            
            appnextExtension = new AppnextASExtension();
            appnextExtension.init("5908545098APPIDEXAMPLE");//Set your AppID
            appnextExtension.showPopup(); //showtheinterstitial
}

```

And this is the error I get:

1046: Type was not found or was not a compile-time constant: AppnextASExtension.

It seems that there’s an import missing for AppnextASExtension…

It should be something like: import.com.AppnextASExtension \<-- right? but with the correct one, of course. Makes sense?

Or maybe with the:

var appnextExtension:AppnextASExtension = null;

They are trying to skip that error, but is still popping up… (?)

Thanks in advance!  
Cheers,
