Featured FLA
» Author: Bugra Ozden
» Title: Skatalog v9 - product catalog
» Description: Create your product catalog easly and publish on your website or Create your image gallery, documents list, portfolio. Fully XML Driven
» More by Bugra Ozden
Featured Site
» Posted in the Flash Kit Links section
» Title: Creative DW Image Show PRO
» Description: Creative DW Image Show PRO is a Dreamweaver extension which enables the user to create multimedia presentations. It combines the features of the popular Creative DW Image Show with the ability to add professional text effects to slides (similar to After Effects). The product is very customizable: the user can choose the duration of the transition effects, the slide motion start and end position, zoom and panning type for both images and texts.
Just real simple, but something that is very useful to know, for reusability purposes or for whatever you may think of.
Steps
Import a sound into your library.
Right click the sound and select linkage then check, Export for actionscripting and Export in first frame
Then in your first frame put
s = new Sound();//declare s as a sound
s.attachSound("buttonSound");//attach the linked sound 'buttonSound' to s
myButton.onRollOver=function(){// make a function
s.stop();//and just so we dont get
//that aweful looping over one sound, we will stop
//it before we start it again.
s.start();//starts the sound
}
This creates a sound object 's' and puts your sound file named 'buttonSound' into 's'. Then creates a function so that when you roll over the button it plays the sound, pretty straight