# Class help with .as files (Quick Novice)

**URL:** <https://forum.kirupa.com/t/class-help-with-as-files-quick-novice/316946>\
**Category:** flash\
**Created:** [December 6, 2010, 4:42pm UTC](https://forum.kirupa.com/t/class-help-with-as-files-quick-novice/316946 "2010-12-06T16:42:43Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![david19801](https://avatars.discourse-cdn.com/v4/letter/d/90db22/32.png) [@david19801](https://forum.kirupa.com/u/david19801)\
**Post date:** [December 6, 2010, 4:42pm UTC](https://forum.kirupa.com/t/class-help-with-as-files-quick-novice/316946/1 "2010-12-06T16:42:43Z")

</div>

Hi guys, I usually make my files on a single .fla file. But now I have a class and don’t know how to set it up.

The file is on website - Bit-101 called “AS3 Sound Synthesis IV – Tone Class” (Please google as I can’t seem to use links here)

I have copied the Tone code into a file called Tone.as.  
Now, where do I put the

```
 ActionScript Code:
 [LEFT][COLOR=#993300]import[/COLOR] flash.[COLOR=#000000]events[/COLOR].[COLOR=#000000]MouseEvent[/COLOR];

```

[COLOR=#993300]var[/COLOR] tone:Tone = [COLOR=#993300]new[/COLOR] ToneCOLOR=#000000[/COLOR];  
[COLOR=#993300]stage[/COLOR].[COLOR=#000000]addEventListener[/COLOR][COLOR=#000000]([/COLOR]MouseEvent.[COLOR=#000000]CLICK[/COLOR], onClick[COLOR=#000000])[/COLOR];  
[COLOR=#993300]function[/COLOR] onClickCOLOR=#000000[/COLOR]:[COLOR=#993300]void[/COLOR]  
[COLOR=#000000]{[/COLOR]  
tone.[COLOR=#000000]frequency[/COLOR] = [COLOR=#000000]300[/COLOR] + mouseY;  
tone.[COLOR=#993300]play[/COLOR]COLOR=#000000[/COLOR];  
[COLOR=#000000]}[/COLOR]  
[/LEFT]

I tried to put it in the .fla and it does not work. I have no idea, any help? Where do I put it, do I need to add anything? and also if you know, do I need to call the filename something specific?

Thanks!
