ActionScript 3.0 :: Updating TextFields - When A New Song Is Played The Text Field From The Previous Tune Does Not Disappear?

May 10, 2011

Im using text fields to display artist, album and song information for tunes that are played in a mp3 player. The text appears fine and with the right information. But when a new song is played the text field from the previous tune does not disappear and the new song information, just sits on top of it.i have attempted to use the remove child to fix this, but couldn't get it working? My code for the play function and the textfields is below,

ActionScript Code:
var myFont = new Font1();
var mySongNameFormat:TextFormat = new TextFormat();
mySongNameFormat.size = 30;[code]...............

View 2 Replies


Similar Posts:


ActionScript 3.0 :: Make Song Start When Played?

May 11, 2009

I have a Music controller, but i want the song to start automatic when the flashfile is loaded. The script is:

var song:Song = new Song();
var myChannel:SoundChannel = new SoundChannel();
var soundVol:SoundTransform = new SoundTransform();

[code].....

View 2 Replies

IDE :: CS4 Constantly Updating Text Field?

Jan 5, 2011

I have a couple of text fields in my Flash movie that are constantly updated with text from an xml document. The xml document is updated through an interface on a seperate swf. It's based on a flash guestbook I found and have hacked apart, and everything works fine in theory... My main worry is that over the course of a day it loaded in the text 170,000 times: 30 times a second which is a little excessive and is playing havoc with my web stats. I've cut this down to once every 10 seconds but I'm still thinking I should use a better method, would it be possible to test for changes before I load in new text, or am I going about this entirely the wrong way?

var currPage = 0;
var showAmount = 1;// set this to the amount of entries you want to view at a time
// **** Load XML ****************************
myXML = new XML();

[code].....

View 2 Replies

ActionScript 1/2 :: Text Field Not Updating Because It's On Another Frame?

Oct 21, 2009

Yet again, I have another simple problem. I have an input text field and a movie clip that contains a dynamic text field. The dynamic text field updates when the user types. Simple enough. However, when I add a frame to my main timeline and cut/past my mc on it, the dynamic text field doesn't update. Here is my simple .fla file showing what I'm trying to do.

View 3 Replies

ActionScript 3.0 :: Flash - Text Field Not Updating?

Nov 15, 2011

Code:
private var lvl:Number = 0;
private var total:Number = 0;

[code].....

View 2 Replies

ActionScript 2.0 :: Event Is Trigger When A Song Is Played And Finished Playing?

Jan 28, 2010

i'm just new to actionscript, how will i trigger an javascript function when i click the button play and also when i finished playing an mp3 file song?

View 0 Replies

ActionScript 2.0 :: Function Not Updating Text Field & Variable

Jan 12, 2009

I have a function that is suppose to update a variable which updates a textfield and it is not working.

[Code]...

View 0 Replies

ActionScript 2.0 :: Cursor At End Of Input Text Field After Updating

May 29, 2008

I have a multiline input text box which a user can type stuff into, then click a button which will save what they typed and load another lot of text (all using XML). What I would like is to set the flashing cursor to the end of this box when it is updated. I've tried a few things:

Code:
Selection.setFocus(_parent.journalentry);
Selection.setSelection(0, 0);
_parent.journalentry.text = (c.firstChild ? c.firstChild.nodeValue : '');

[Code]....

View 1 Replies

ActionScript 2.0 :: Text Disappear When The User Clicks Into The Login Field?

Jun 16, 2004

I know it exists, but I just can't figure it out. from the site I created, [URL] the login is obviously input text. How can I have the text disappear when the user clicks into the login field?

View 3 Replies

ActionScript 2.0 :: Have The Text Disappear When The User Clicks Into The Login Field?

Jun 16, 2004

I know it exists, but I just can't figure it out.from the site I created,[URL]the login is obviously input text.How can I have the text disappear when the user clicks into the login field?

View 3 Replies

ActionScript 1/2 :: Clear Previous Links In A Text Field?

Sep 9, 2010

I'm loading data in to textbox1 and on click I load more data in to textbox1 by replacing the existing data. Every time I load data there are hyperlinks in the text. Now I need to clear all the hyperlinks that was there when I click my next button to load more data. How can I clear all the links within the textbox when I click a button?

e,g,
//1st load
for(var i:Number=0; i<messageA.length; i++){

[code].....

View 1 Replies

ActionScript 3.0 :: Mp3 Player Functions - Create Next And Previous Song Buttons

Jan 27, 2009

I don't really use Flash anymore but have been approached by a client to work on a simple-function mp3 player with play, pause, prev, and next song buttons for their website. I'm using [URL] and wanted to learn how to create next and previous song buttons. Here is my code:

[Code]....

View 1 Replies

ActionScript 2.0 :: Previous And Next Buttoms In Gallery - How To Make Them Disappear?

Feb 16, 2009

I have the following website: http:[url]....A portfolio website based on a flash file which communicates with a xml file... code mixed togeather from some tutorials.The problem, is with the "previous" and "next" buttons: I dont know how to make them disappear when there isnt another image link in the xml file.

Action script:

Code:
function loadXML(loaded) {
if (loaded) {[code]...........

View 4 Replies

ActionScript 2.0 :: Previous Displayed Image To Disappear / When Any Other Button Is Clicked

Aug 21, 2010

I need to make a series of 35 buttons that display an image when clicked. However, I need the previous displayed image to disappear when any other button is clicked.I have this to toggle the images on/off:[code]Any idea what I can add to the function to turn all the other buttons visibility to false when any other button is clicked?

View 2 Replies

ActionScript 2.0 :: Conflict Between Two Mc Buttons - Make Disappear The Previous Submenu

May 12, 2008

I'm just a beginer with actionscript, in this case actionscript 2. I have two mc buttons mc_one and mc_two. When I click on mc_one apear a submenu, and when I click on mc_two apears another submenu in the same place than the mc_one submenu.

I know how to make disapear the previous submenu by tell _visible = false, but I also want to finish and bring back the submenu in their initial position in order to not to wait that the function finishes for open the new one. Maybe something like null or reset the function that make the other submenu turn up with no problems.

View 3 Replies

ActionScript 3.0 :: Mp3 Title List - Stop Button Should Move From Song To Song When Playing?

Aug 19, 2009

I have a list of mp3-songs, when song 1 is clicked it gets streamed, a stop-button appears, if this Btn is clicked, this Btn disappears as it should - but if user forgets to click for stopping sound and clicks song 2, stopBtn 1 remains and the new stopBtn 2 also appears. there should be only one stopBtn, the one next to the song is playing.

I would like to move the stopBtn and I have tried several approaches move; graphics.moveTo; if(stopButton !=null) {removeChild (stopButton)}; I packed the var stopButton:Sprite in the header and so on.

Code:
SoundMixer.stopAll();
import flash.display.Sprite;[code]..........

View 0 Replies

Tune Performance Of FMS?

Mar 28, 2011

It's OK on develop machine,
 
but when put on product machine,it's extremely slow...
 
The real time publishing often turns out a static image hanging there.

View 1 Replies

ActionScript 2.0 :: Pass Text From Form Text Field To A Flash Dynamic Text Field?

Feb 3, 2007

Currently I'm using javascript which works fine to pass text from textfield A to textfield B:

Code:
window.onload=function()
{
document.forms.form1.shirtText.value=document.forms.form1.KitGroupID_16_TextOption_38.value
}

Is there a way to pass the textfield A text to a dynamic text input (flash) as I'd like to use the font embedding flash offers. I can make it work when loading a value from a txt file but I'm not sure how to access the value identified above as KitGroupID_16_TextOption_38 and make it appear in a dynamic input box. Eventually I might want to have 3 font choices for the user but I'd like to just see if I can get this working properly first.

View 1 Replies

ActionScript 3.0 :: ID3 Tag - Getting The Song Length Before The Entire Song Has Been Loaded?

Feb 15, 2010

I am writing a mp3 player and having some issue getting the song length before the entire song has been loaded - which messes with my position indicator, as it needs to know the track length. I thought I could get the length from an ID3 tag, problem is ID3.TLEN returns undefined, though if I right click the track and show properties, the summary tab shows song duration, bitrate, etc... how I can retrieve the song length before the entire thing has been downloaded?

View 4 Replies

ActionScript 2.0 :: PHPBB - Login Through Flash Using One Dynamic Text Field And One Input Text Field And No Buttons?

Jul 17, 2003

Is it possible to login through flash using one Dynamic Text Field and one Input Text Field and no buttons? If so how? I have seen many tutorials dealing with logging in to PHP using flash but it requires you to make your own php scripts which i am not familiar with. Can some one tell me how to do this with PHPBBs existing php scripts... I want to be able to login thorugh a Input Text Field box and have it verify it in PHP and also be able to register and view other PHP info such as users online and FAQ..

View 2 Replies

ActionScript 2.0 :: Calculator - Clear The Text Field Then Store The New Input In The Same Text Field As A Different Variable

Mar 30, 2006

I'm making a calculator using Flash MX that works the same way as the basic calculator found on windows (not the scientific one). But having the user input a number, store it as a variable, store which function the user wants to perform and clear the text field then store the new input in the same text field as a different variable and multiply or add or divide or subtract the 2 numbers and getting the equals sign to display the answer when clicked is harder than I thought it would be.

View 3 Replies

ActionScript 2.0 :: Contents Of A Text Field As The Dial Points In The Direction Of The Text Field?

Nov 15, 2004

I am working on a file that has a rotating dial, and I'd like the dial to reveal contents of a text field (a link) as the dial points in the direction of the text field. I have 4 text fields located at 90, 180, 270 and 360 degrees (top, bottom, left and right). I have it controlled via AS, so I've got all the Math but I was hoping someone might know how to reveal the links when the arrow (in the dial) is pointing in these directions.I set up a text field for testing, which shows the degrees, but I'm getting 'NaN' in the field (problems with Theta and converting degrees to Radians, I think). I thought this might help me figure out how to reveal those links, if I can get the NaN to work.Currently, the file is rotating with an onPress, but I'm going to convert it to a mouse follow, instead, so the user only has to float around to see the links.

View 5 Replies

ActionScript 2.0 :: Dynamic Text Field From An Input Text Field

Dec 16, 2010

What I'm trying to do is to write something in an input field and then it should show up in a dinamic field. I can make this happen, but the problem is that the dinamic field shows its new text in the same format as the Input field. For example, the input text is written in TimesNewRoman and the dinamic text is in Arial, but when the dinamic text shows the input, the text is still in TimesNewRoman when I want it to be in Arial.

View 11 Replies

Professional :: Pass The Contents Of The Text Field To Another Text Field?

Nov 8, 2010

I've created a dynamic text field - mediaImportName001 (created , and populated it with the name of a file that I choose to import using a browse button (as3 and AIR).This works fine - I can import the file, and the name appears in the field.
 
I'd now like to pass the contents of the text field to another text field.  But I can't get the contents. If I try to trace the contents of the textField trace("mediaImportName"+thisNum).text     - Flash returns "undefined" (even though I'm asking it to trace after the field has been populated).
 
I use the following code to check that the field really is there and named correctly (the code returns the children):
 
for (var i:uint = 0; i < this.numChildren; i++){    trace (this.getChildAt(i).name + ' type:' + typeof (this.getChildAt(i))+ ' ' + this.getChildAt(i));}
 
it returns:
 
instance370     type:object    [object Shape]mediaImportName001     type:object    [object TextField]mediaFiletype001     type:object    [object TextField]
 
How do I get Flash to give me the text in mediaImportName001?  
 
It's bizarre - this.getChildAt(i).name
 
from above gives me...
 
mediaImportName001     ,
 
yet
trace (["mediaImportName"+thisNum].name); 
 
returns undefined (thisNum represents an increment I use to name multiple clips and text fields, and in this case trace(thisNum); returns 001)

View 4 Replies

ActionScript 1/2 :: Play Song Using External Text File?

Sep 1, 2006

I have this text file text.txt and it has a variable in it named song1 with the url of a song file. In flash, I set up this actionscript:

onClipEvent (load) {
loadVariables("text.txt", "_root");
var my_sound:Sound = new Sound();
my_sound.loadSound(song1,false);
}

the problem is that I get an UNDEFINED message for the variable song1. But, if I put it in for the variable of dynamic text, the text will show up in the exported flash. I suspect it has something to do with where the variable is being exported to.

View 3 Replies

Professional :: Applying Text Format To ComboBox Makes TextField Text Disappear?

Oct 25, 2010

When applying text formatting to a comboBox, the text formatting appears perfectly on the dropdown menu items but the textField text disappears.Removing the text formatting from the textField makes the textField text reappear but of course there is no text formatting.
Is there a trick to this.

View 9 Replies

ActionScript 2.0 :: EmbedFonts Makes Text Disappear - Dynamic Text Vertical Position?

Aug 7, 2003

I have the following code:

Code:
this.createTextField ("imageText",2,95,0,390,96);
imageText.multiline = true;
imageText.wordWrap = true;[code].....

The problem:If I uncomment either of the imageText.embedFonts lines, my text will disappear... but the trace(imageText.text); will still return the correct contents. It's as though embedFonts causes the textField to disappear.Possibly related, (but maybe not), is the fact that the vertical positioning of the font is off. Even though I create the textField at Y = 0, the text writes somewhere around Y = 10. I suspect this is something else, but I thought I'd add it just in case.

View 3 Replies

ActionScript 3.0 :: Compare Dynamically Generated Textfields Text With Xml Text?

Mar 18, 2011

how to compare the text of dynamically generated textboxes with xml value. the instance name to the textboxes are assigned at runtime.

View 3 Replies

Skewed Dynamic Text Box Makes Text Disappear?

Jun 25, 2009

When I skew a dynamic text box, the resident text disappears.

View 1 Replies

ActionScript 2.0 :: Make The Text Already In The Input Text Box Disappear?

Apr 9, 2003

how to make the text already in the input text box disappear when you click on it.

For example:

|enter email| - this is loaded when the page is loaded

|_________| - then disappears when you click to type

: : I thought it would be very simple, but i guess not : :

View 9 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved