# Error Thrown When I Add AS to Timeline. Class Interfere?

**URL:** <https://forum.kirupa.com/t/error-thrown-when-i-add-as-to-timeline-class-interfere/260786>\
**Category:** flash\
**Created:** [May 19, 2008, 9:57pm UTC](https://forum.kirupa.com/t/error-thrown-when-i-add-as-to-timeline-class-interfere/260786 "2008-05-19T21:57:23Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![DrRobot](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/drrobot/32/3907_2.png) [@DrRobot](https://forum.kirupa.com/u/DrRobot)\
**Post date:** [May 19, 2008, 9:57pm UTC](https://forum.kirupa.com/t/error-thrown-when-i-add-as-to-timeline-class-interfere/260786/1 "2008-05-19T21:57:23Z")

</div>

Alright, so i am working on a game, and i have a document class set. now i want to add some AS to the main timeline, such as a preloader and other little things. but when i do put some AS on the timeline, it throws this error:

```auto

1180: Call to a possibly undefined method addFrameScript.

```

and highlights:

```auto

package {

```

as the target/source of the error.

Any solutions to this?

---

<div class="post-metadata">

**Author:** ![krilnon](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/krilnon/32/34_2.png) [@krilnon](https://forum.kirupa.com/u/krilnon)\
**Post date:** [May 19, 2008, 10:03pm UTC](https://forum.kirupa.com/t/error-thrown-when-i-add-as-to-timeline-class-interfere/260786/2 "2008-05-19T22:03:24Z")

</div>

I don’t think that you can have AS on the timeline and have a custom document class because the AS on the timeline is converted into part of a document class if you don’t specify one.

However, you can add the code that you would have had on the timeline using _addFrameScript_: [http://www.kirupa.com/forum/showthread.php?p=2098268](http://www.kirupa.com/forum/showthread.php?p=2098268)
