# Accessing a Subclass (swf)'s library items

**URL:** <https://forum.kirupa.com/t/accessing-a-subclass-swf-s-library-items/290478>\
**Category:** flash\
**Created:** [June 15, 2009, 5:02pm UTC](https://forum.kirupa.com/t/accessing-a-subclass-swf-s-library-items/290478 "2009-06-15T17:02:02Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![k0nG](https://avatars.discourse-cdn.com/v4/letter/k/858c86/32.png) [@k0nG](https://forum.kirupa.com/u/k0nG)\
**Post date:** [June 15, 2009, 5:02pm UTC](https://forum.kirupa.com/t/accessing-a-subclass-swf-s-library-items/290478/1 "2009-06-15T17:02:02Z")

</div>

Hi Kirupa!

I’m using a preloader to load an external SWF then initiating it through its document class using this code:

```auto
    [FONT=&quot]private[/FONT][FONT=&quot] [COLOR=#7F0055]function[/COLOR] loaderCompleteListener(event : Event) : [COLOR=#7F0055]void[/COLOR] {[/FONT][FONT=&quot][/FONT] 
[FONT=&quot][/FONT] [FONT=&quot] [/FONT][FONT=&quot]var[/FONT][FONT=&quot] loaderInfo : LoaderInfo = event.target [COLOR=#7F0055]as[/COLOR] LoaderInfo ; [/FONT][FONT=&quot][/FONT]
  [FONT=&quot] [/FONT][FONT=&quot]var[/FONT][FONT=&quot] myMainApp:MyApplicationClass = loaderInfo.content [COLOR=#7F0055]as[/COLOR] MyApplicationClass;[/FONT][FONT=&quot][/FONT]
  [FONT=&quot] [/FONT][FONT=&quot]addChild(myMainApp);[/FONT][FONT=&quot][/FONT]
  [FONT=&quot] [/FONT][FONT=&quot]myMainApp.initialise();[/FONT][FONT=&quot][/FONT]
  [FONT=&quot]}[/FONT][FONT=&quot][/FONT]
  

```

The problem i’m getting is that the Flash that is being loaded has a lot of classes exporting on the first frame, which now cannot be accessed, and therefore I get “The definition of base class cannot be found” errors.

How do I ger the items in the library that export to AS accessible by the parent loading SWF.
