Dopo aver visto in un post precedente, http://bestar-space.blogspot.com/2009/04/gestire-con-flash-la-musica-di.html come gestire con flash e ActionScript la musica di sottofondo del nostro sito o blog, qualcuno giustamente mi ha chiesto(dico giustamente perche mancava il pulsante pausa)come si fa a mettere in pausa l'audio, tramite un pulsante gestito con actionscript.
Iniziamo:
Create due pulsanti:
play > con nome istanza > inizio
pausa > con nome istanza > pausa
importa nella libreria il file audio e in Proprietà Concatenamento inserite come Identificatore il nome > audio
nel primo fotogramma inserite il cod AS sotto:
-----------------------------------------
suono=new Sound(this);
suono.attachSound("audio");
pausa.onRelease=function(){
suono.stop();
};
inizio.onRelease=function(){
suono.start(suono.position/1000,999);
};
--------------------------------------------------
Provate il filmato..
Abbonati gratis a questo blog
Hi Sweetie,
How are you? How was your weekend, mine was very nice, it was really hot here, I loved it !!! =) Did not have the big party but had a few friends over for a little get together, spent some time in the pool, had a few drinks, was very nice =)
How is your aquarium coming along? Can't wait to see it =)
Many hugs to you xxxxxxxxxx
Hi ! How are you ???? I haven't heard from you in a while, is everything alright? It's raining here, but it is a warm gentle rain, the flowers needed a drink =) Nothing much going on here, just trying to deal with summer being almost over, I like autumn when the trees start to change colors,but I don't like when all the leaves start to fall off the trees. Hope you are doing great!!
Lots of hugs
Hi My Dolce Bestar,
I am happy to hear you are doing well, and that you got a chance to get away for a couple of days, if I could go to the sea I would too !!! I love the water and I truly love being on the beach, a lot of excitement during the day and so peaceful and romantic in the evening =) I have not been to the ocean in a few years, I miss it a lot !!!! You will have to take some pictures and then post them on here so I can see =)
My birthday is on Monday (August 24th) and I am not sure what I am going to do yet, probably have a little party with just close friends and family. Would like to get away for the weekend, but money is kind of tight right now, so will have to wait until I can afford it =)
Many hugs to you
My Dearest Bestar,
You are THE BEST !!!! Thank you sooooo very much, I LOVE my gift. You are incredibly sweet and soooo talented !!!!! I love that you included the Beatles =) You have made my birthday a wonderful one, I am so happy that we are friends! Many many hugs and kisses to you !!!!!!!!!
Hello Dolce Bestar,
Thank you for leaving the information 8-)
Heyyyyy you have emoticons now, nice!!!!
Do you have big plans for the weekend?
I am going to a carnival where there is a band that are kids that range
in age from 14 to 17 that have a band called crooked X,
they play rock and heavy metal songs and they really sound good
http://www.youtube.com/v/SoIkoi3dl-A&feature
I will let you know how it goes ;)
Other than that not much going on. Sending you lots of hugs and :* 's
Hi Sweetie,
I am great, thank you. The message with the video was from me, I see it says guest =)
I had a great birthday, thank you =) And that concert was really great too =) There was a cover band that did music from ac/dc, I was rocking out =)
How are you doing???? I hope everything is great, the weather here is rainy, rainy, rainy, it is still warm but cooler than it is supposed to be. I am shutting down the pool this weekend, putting the cover on it =( I will miss it until next summer.
Many hugs and kisses
Hi Sweetie,
I am great, thank you. The message with the video was from me, I see it says guest =)
I had a great birthday, thank you =) And that concert was really great too =) There was a cover band that did music from ac/dc, I was rocking out =)
How are you doing???? I hope everything is great, the weather here is rainy, rainy, rainy, it is still warm but cooler than it is supposed to be. I am shutting down the pool this weekend, putting the cover on it =( I will miss it until next summer.
Many hugs and kisses
Awwwwww, you are so sweet, you don't have to worry, I am always here =)
It has been a very lazy weekend, not much going on.Next weekend maybe, I am going to the renaissance festival here in Kansas City, KS, it is a lot of fun it is a 16th century village with crafts, shows and food
here is a website where you can see what it has
http://www.kcrenfest.com/favs.html
I hope your weekend is peaceful and relaxing
Tons of hugs and kisses to you :*
Ciao Bestar, come stai ?
Sono rientrata dalle vacanze.
Quando potrò vedere qualcosina di nuovo sul blog di prova?
Un abbraccio affettuoso.
Hi !! How was your weekend? Mine was a lazy, stay at home and do nothing weekend =),a couple friends came by, it was nice. I haven't gotten the chance to go to the festival yet, something always comes up when I try to plan things =) Hope to go next weekend though.
I hope this week is great for you !!!!
HUGS, HUGS and more hugs
ciao carissimo,
finalmente ho fatto un salto sul tuo blog... ma quanto scrivi! complimenti, ci son molte cose interessanti anche per una "capra" come me (in senso lato eh! beeee scherziamo?!)
chissà se capisci chi sono... bè mi sa che ci vediamo presto, cmq. io appena rientrata dalle ferie... ti lascio un indizio fotografico.
spero tutto ok nella tua vita!
bye bye
"chinese girl"
@ <span>"chinese girl"</span>
Anche se ci siamo salutati di persona, ti do il benvenuto anche sul blog...
Grazie del benvenuto! Chissà che non riesca ad imparare qualcosa frequentando questo luogo...
Ciao Bestar, ti auguro una bella e luminosa giornata!!
"chinese girl"
Ciao <span>"chinese girl"</span>
A disposizione....
NB: Spero tu abbia fatto delle foto a Londra...
Buona Serata...
effettivamente... qualcuna... per la precisione 1.200!!! :) la mia prima reflex l'ho battezzata bene!
la foto che ti avevo allegato è il "London Eye" tra le nuvole.
ciao have a good day!
wowwwwwwwwwwwwwww........
qualcunaaaaa... 8-) = 1200???????????????
1200/30
very cool.............
have a nice day too
sera bestar volevo metere musica di sottofondo nel blog ed ecco subito un problema apro flash clicco file vado su import - library si apre la cartella di importazione musica e cosa trovo tutte cartelle nominate GBM nessuna traccia di wav o mp3 come mai grazie luis.
dimenticavo sto usando adobe flash cs4 professional di nuovo ciao