Text And Actionscript
hey, does anybody know if you can break apart dynamic text with actionscript?thanks,Ceej
KirupaForum > Flash > Flash 8 (and earlier)
Posted on: 04-26-2007, 10:41 PM
View Complete Forum Thread with Replies
See Related Forum Messages: Follow the Links Below to View Complete Thread
How To Add Text To A Dynamic Text Feidl In A Movie Clip Added Through Actionscript?
ok I've never been able to get this to work so I've always just found a way around it. But I really need to get this to work in this project.
I need to get dynamic text to change in a movie clip Where you are adding the movie clip through actionscript (its not on the stage, you are adding to trhough createEmptyMovieClip). I can change dnamic text in a movieclip that is already onthe stage and thats usually how I get around this, but I really need to add it through createEmptyMovieClip this time.
The follow doesn't seem to work and I've searched everywhere all they all say this is how you do it but I can't get it to work...
///////////////////////////////////////////////////////////
//create an Empty movie clip
var CountLayer:MovieClip = home.createEmptyMovieClip('CountLayer', 5);
//add the movie clip to the empty movie clip just created
CountLayer.attachMovie('ScoreCount_mc', 'ScoreCount_mc', 0, {_x:400, _y:400});
//test variable
var test:Number;
test = 0;
//Add text to the dynamic text in the movie clip
ScoreCount_mc.Score_txt.text = test.toString();
////////////////////////////////////////////////////////////////////
The above never seems to add anything to the dynamic text feild. So if anyone know whats going on here or the right way to do it please help.
Thanks.
Actionscript: Email Text From An Input Text Field Problem.
I am having difficulty with my email example.
I am using Flash mx2004 pro 7.2
(This example needs to be viewed in a explorer browser)
My first problem is that when you type in the & Character into the input text field.
The text following the & Character cuts out when sending info to the outlook program..
The code on my send button looks like this:
on (release) {
getURL("mailto:Youraddress@domain.com?subject=Stan dard title"+"&body="+body);
}
I would also like to find out if it’s possible to retain text format from a copy/paste job into a input text field that translates all the way to outlook.
Thanks for any suggestions you may provide.
~Josh
Text Input / Text Output...help With Actionscript Required..
hi
I have 2 text input boxes (input1 & input2) and 3 text output boxes ( output1 & output2& output3), also there are 2 buttons to add the text from the input boxes to the text output boxes.
What i need to do is this:
i input text into the 2 text input boxes and when i click the button for input 1 i want it to add the text from input1 to output1,i might then need to add input1 again and i want it to display in output2 as well as output1, then i might need to add input2 and i then want it to display in output3, then again i might want to add them in a totaly different order but always moving to a new output box if the above one is already full.
i hope you understand the gist of what im getting at and your help would be greatfully received.
thanx in advance
Import Text Directly Into Actionscript From A Text File?
I have a flash movie Im working with where, at the moment, there is a variable that carries some text used in another part of the move:
This is the actionscript within the movie that deals with it:
ScrollingDisplay1:Message = "Scrolling LED display...";
ScrollingDisplay1:MaskWidth = 10;
call("ScrollingDisplay1/:Initialise");
stop();
the line with "Scrolling LED Display..." is the current text that is used in another part of the move.
What I need to do is draw in text from a text file and directly insert it inbetween the " " part on line 1 of the above script. I know how to import text and insert it dynamically into a separate text box, but I cannot find any online help as to how to insert text directly into Actionscript dynamically from a text file.
The text file Im currently using looks like this:
&gk_text=This is test text which will appear in the movie
As you can see, it declares itself as a variable "gk_text"
The file is called text2.txt
I know that to begin the code to link the text file is
loadVariables("text2.txt","_root");
But thats as far as I can take it.
If anyone can help and let me know how it can be done, Id appreciate it.
Many thanks
Wayne Dorrington
Import Text Directly Into Actionscript From A Text File?
I have a flash movie Im working with where, at the moment, there is a variable that carries some text used in another part of the move:
This is the actionscript within the movie that deals with it:
ScrollingDisplay1:Message = "Scrolling LED display...";
ScrollingDisplay1:MaskWidth = 10;
call("ScrollingDisplay1/:Initialise");
stop();
the line with "Scrolling LED Display..." is the current text that is used in another part of the move.
What I need to do is draw in text from a text file and directly insert it inbetween the " " part on line 1 of the above script. I know how to import text and insert it dynamically into a separate text box, but I cannot find any online help as to how to insert text directly into Actionscript dynamically from a text file.
The text file Im currently using looks like this:
&gk_text=This is test text which will appear in the movie
As you can see, it declares itself as a variable "gk_text"
The file is called text2.txt
I know that to begin the code to link the text file is
loadVariables("text2.txt","_root");
But thats as far as I can take it.
If anyone can help and let me know how it can be done, Id appreciate it.
Many thanks
Wayne Dorrington
Text Spacing When Using Actionscript For Text Effects
help please!
i am using action script to create some text effects for a variable string, the code is simple like below ... taking each character of the text string and attaching a text effect movieclip for that character.
the problem i that the letters appear with a wide range of spacing (from no spacing - to lots of space) between the letters of my text string after it is output.
i have set a kern value and simply multiply the character count * the kern value. shouldn't this keep a standard spacing between the letters?
Thanks in advance,
Shane
------------------------------
example:
------------------------------
should look like:
Hi computer user.
but instead the output has weird spacing:
Hi com put er us er .
-------------------------------
My actionscript code:
-------------------------------
account_name = "Hi computer user.";
count = 0;
kern = 16;
if (count<account_name.length) {
this.attachMovie("text_fx", "text_fx"+count, count);
this["text_fx"+count]._x = count*kern;
this["text_fx"+count].text_var = account_name.charAt(count);
count += 1;
}
Set Text Property Of Dynamic Text Via Actionscript
I am using a form application, and am trying to setup a login screen. On the login screen I have a text field named txtDisplay. The field is set to DynamicText.
I want to use this text field to display a message back to the user if their login fails. In testing, I am trying to set the text property to some test string when a button is clicked. Here is the code that I am using:
on(click) {
txtDisplay.text = "TEST"
}
I know that the on(Click) event fires, because I used this same even to show a different form within the application, and it worked fine. I just can't seem to be able to set the text value of this object. I have tried using a label component, and again was unsuccessful.
The instance name of this form is login. This is a nested form under the toplevel form cms - if that helps.
Any help on this is greatly appreciated.
Thanks,
Ron
rivey@izinteractive.com
Put Text In A MC With Actionscript
hai, I have asked this yesterday but the answer didn't work.
i want to change a text field in side a MC (_root.mymc.mytextfield = "the text i want"; does not work)
is there an nother way to do this.
thanx
Actionscript Text
I don't know how to really word this but here goes. I want to make a button. When the visitor waves over the button the text changes in the dynamic text(there are couple of buttons.) I know set a variable for the text box. But what action do I give for the button. This is kinda like text with action script. If you need more details ask away. Thanks!
Actionscript Text
Is there a way to make text created with actionscript not selectable in the published movie?
thanks,
dave
Text In Actionscript
I'm currently working through a tutorial for creating scrollbars for text in MX, all is well apart from the tutorial I'm using places the text in action sript:
my_text ="blah blah blah..."
showText(my_text);
I need to place line breaks to seperate paragrphs to the text but do not know how to do this in actionscript.
Simply htting return to create the breaks ruins the actionscript so nothing works!
Who has the answer????
Please help!
Text Box Actionscript.
ok i have a blue dot... in a MC....in the next frame i have a red dot...and the next..a green..ect.
ok when i press a button the colour of the dot changes(frame changes) thats all good and working now what i need is:
depending on what frame "DOT" mc is on: depends what word is shown in a text box on the normal timeline(the first frame)
so when the frame green dot is showing the word "green" will be showed on a different timeline.
So basicly something in the action sript of a frame to add a word to a text box not in the mc.
how do i do it?
sorry about the massive amousnt of misspells
Actionscript And Text
Hey all, I'm trying to make an actionscript based text animation:
var text = "Ummmm, yes this is my prol33t typing script...omg at 30fps ;o"
Thing is, how would I add a " so that it appears, and doesn't mess up the actionscripting?
I want it to say something like "Ummmm, yes this is my prol33t typing script..." omg at 30fps ;o
Text On ActionScript 3.0
I don't seem to have much success with this method of exchange, (so far zero success rate). I would be grateful for any information on books available on ActionScript CS3. All the books I have found are on previous versions.
Books can be ordered in local stores. Online purchase is a problem at the moment.
hopeful
Little Help With Text And Actionscript :-/ Plz
Hey, I'm making a chat program. and I want it to have a popup screen to login I've got everything in my head planned out right its just not working I've already had it working. but I can't get the name to stay in the text feild. cuz when I remove the movieclip it removes the name they typed in. and when I move it in a different frame. it removes the text... so every time you try to send a msg. it tells you to login. but it should be logging... anyone wanna try to help? if so contact me on MSN, AIM, or Y!M.
MSN: aaronslife@gmail.com
AIM: aaronslife2005
Y!M: aaronslife2005
Help With Actionscript Text Input
I want to create a math problem that the user inputs the data to be computed.
example:
220 - textinput = answer
I just started with scripting. I know Lingo fairly well and now trying to learn actionscripting.
Thanks
Text Effects With Actionscript
I am trying to make a text effect function that breaks apart a string into separate movie clips where each movie clip contains one letter in a Dynamic Text... Problem is, when I set the _rotation or _xscale or _yscale, it doesn't do it to the letter, so how can I break apart the text using actionscript, or some other way to make this work?
Actionscript Text Operations?
Hi,
I have several text input boxes and I'd like to save the entries in different variable and then perform mathematical operations on them and last but not least give the output in a dynamic text field
Could anyone plz explain me how to do this? .. or tell me where i could look it up?
thx
meg
Set Color On A Text With Actionscript?
How do i set a color on a dynamictext with actionscriptning..
I have this variable that contains two words one of the words should be black and the other should be red.. Can I do this with actionscript?
Actionscript And Text Animation
Hi all. I'm quite new to flash, but know a little about it.
What I'm trying to accomplish right now is to get input from a text file, load it into a flash movie and change the alpha and colour of it.
Here's my problem. I can do one or the other but can't get both to work.
I've got 2 dynamic textboxes (FirstName and LastName) in symbols(movie clips) of the same name. I've got several keyframes changing the colour and transparency of the text. This part of it works.
I've also got loadvariables in frame 1.
[loadVariablesNum ("namevars.cfm", 0, "POST");]
I've got a dynamic textbox (no symbol created) with TestID, and when I test the movie, this textfield gets the info from the loaded file.
I can't seem to get the textfields FirstName and LastName to aquire the variables though.
I'm not sure what I'm doing wrong, so I figured I'd post here.. can anyone help me with this?
Thanks in advance,
WebRiffs
Moving Text With ActionScript
Please Help. Instead if setting up millions of timelines for text to appear on my screen, can I use actionscript and apply it to each letter? IF SO HOW? thank you everyone.
Ben
ActionScript In A Text File
I have heard that ActionScript can be placed inside of a text file instead of being put into the Flash file itself. What are the benefits of this and how does it work? Would this work for object and frame actions as well? I'm not too clued up on this so where would you suggest I go to get more information about this?
I would appreciate your feedback
Steve
Text Variable And Actionscript
Hi Folks. I"m relatively new to FLash 5 and I'm having a small prob with inputing a paragraph in into a text animation script. Basically, when you enter the "text" variable into ActionScript, how do you get it to ident for paragraphs or blocks of text? I can only get one extremely long line of text when I play the movie.
Thanks in advance!
Actionscript Or Java In A Text Url :s
Perhaps visually i'm not a newbie but technical i still am..... Is it posible to put a goto command to a text url? I mean you can make it email or go to another site..... But is there a way to give actionscript commands when you push on a textbutton(i mean the url in the character window)?
[Edited by heiny on 02-27-2002 at 04:19 AM]
How To Resize Text Box From Actionscript?
Hello,
I'm trying to resize a text box at runtime from Actionscript to fit the content that will be loaded dynamically from the database. The problem is the text length is unknown and may vary greatly, let's say 1-10 lines. The text can be wrapped to the new line, if it's very lengthy. However, the text may be long enough to exceed the text box height. Furthermore, there will be some graphics right below the text box with a fix distance from the text box. Because of this issue, I cannot preset the text box to be very large to accommodate large content. Is there anyway to determine how many line of text in the textbox, resize it appropriately and be able to determine the bottom coordinate of the text box, so I can place a graphic right underneath it?
I tried to do put the text box inside a movie clip and resize it. The result is the text inside the text box is scale to the new size. It didn't keep the original font size.
If anyone can guide me how to solve this problem, I will really appreciate it.
Chanok
Text Effects Using Actionscript
Trying to create typewriter text effect using actionscript.
i can get the line going but i wants to create paragraphs and i have not idea how to create a line break.
Can someone help.
Formating Text In Actionscript
Is the only way to format text in actionscript MX by setting the text to HTML and using the very limited HTML formating?
eg.
text1.HTMLtext = "<p>first paragraph</p><p>second paragraph</p>";
If this is the case it really limits the usefulness of Flash . I had planned to store the text in a database and output one version of pages for the search engines and the few visitor without Flash, but have most visitors surf Flash based pages. This is what Macromedia are suggesting but if I can't even format my stored text what's the point. The limited HTML commands don't even support images!
Text Effects With Actionscript?
hi all,
i'd like to create a text effect like the one in this site:
http://www.elearnsight.com/
the letters 'our vision' rippling across is what i want.
i've used swish in the past for text effects, but i'd like to know (if poss) how it's done in flash. i don't fancy having to do a tween for each letter, so i'm hoping that it can be done with actionscript
if anyone can help, then i really appreciate it
cheers
Animating Text With Actionscript
Hi-
i am somewhat new to Actionscript, but have enough understanding to disect what somebody gives me to look at.. here's my question. I have used Swish before to create text effects, but i want to learn to do it using Actionscript. Some time last year, i followed a tutorial that showed me how to make text effects by loading my text into an external text file, Inside the flash movie, if i remember correctly, I created a movie clip that would hold a letter "M" of whatever font i wanted. The capital M was to make sure that all letters would fit into the MC, since it is the widest and tallest of all the letters. I animated the movie clip however i wanted, and the actionscript would pull one letter at a time from the text fine and animate it along the motion path i set up... at the time that i did the excercise, i didnt fully understand. Now that i have a little more understanding of actionscript, i'd like to learn this.
if anyone can suggest a tutorial or show me the proper script to do this, that would be great... also, if you have a sample FLA file that i can study, that would be even better.
thanks
-myk
Text Editing Actionscript
Okay, I have 194 different movies with buttons embedded within each one, and on each one, I am calling 1 of three functions. A rollOut, rollOver and press function, but they were on a seperate layer, referenced by _parent. I've have resrtuctured my site, and I need to change each one of them from _parent to _root. But here's the deal, I can't really just install three functions on my parent and have THEM reference the _root.function because I will be importing this movie into various otehr gui's...is there any way to go through all these lines of code and change one word to something else?
- Jeremy
Animating Text With Actionscript
Lets try this again...
can anyone point me in the right direction? I'm trying to learn how to animate text with actionscript. ANy links to a good tutorial, or can someone post a saple .fla or script i can study? What i'd like to do is either read from an external text file or maybe assign my text to a variable in actionscript and have a movieclip that follows a motion path. I suppose this would be done in some way by slicing one letter at a time from the text or variable and running it along the path at whatever speed it needs to be run. I think i understand the concept, but the script is stumping me. I'm looking to learn how to do what 3rd party programs like Swish do, except i wanna learn to do it "the old fashioned way."
Thanks
-myk
Actionscript On Fade Text
Hey i need help, agian. Sorry for repediatly bothering everyone but i still don't get it. Heres my new upadted site http://jcs1287.tripod.com/es3.htm ( please wait for the intro, i'm sorry i haven't had time to fix it, u can't skip, but it's only 45 seconds so please just wait) .. Now as you see that my fade text( when you put your mouse over the pickture it fades. But as u can see my text is also in that pickture, and it fades with the pickture. I need it so my pickture fades, and the text comes up, then when the mouse isn't over the pickture anymore the text dissapears and the pickture reapears. It is similar to this web site http://nasi01.epicurissimo.com/ . I already know the action script to pickture, now all i basically need is one for the text to come up out of no where. Thanks agian for all the help.
Jason Stimac
Input Text & ActionScript
If anyone can help I'd be grateful. I would like to simulated a database without the database. I have an input text field, a submit button and four subpages called 1, 2, 3, 4. What I would like is that when someone types in 3 and hits submit, it takes them to page three, type 2 and they'll go to page two and so on. If they type in a variable that isn't there it will prompted them to reenter a new number. Can anyone help?
Input Text & Actionscript
How do you make the movie go to the scene which is typed in the input text field? I have this:
on(release){
usertext = "david";
gotoAndPlay ("david",1)
}
which works, but I have four labeled scene that need to be accessible from the input text box. How do I do this?
Actionscript For A Dinamic Text Box?
Hello!!
well, i have a problem cause i want to load a txt file in a dinamic text box when i click a button!°!!
but the text file has to be from and external file.
how can i do that????
thx for your help!
i hope you can help me!
darksonreturns
Text Effects Using Actionscript
I need to create a header filled with text effects using actionscript but I'm new to the language and dont know quite how to do this yet. I'm looking for information eather on how to set this up in flash MX or for a program to work with that genorates good effects and can be integrated into flash MX. Flashtyper is currently down. Can anyone help?
thank you
Actionscript For Text Effect
I need to do some text effects for a presenation. It takes so long to do the effect I want, I have tried to explore actionscripting as an alternative and am stuck.
I have 6 letters, they are in 6 different dynamic text fields. I have labeled their instances individually. How can I add actionscript to make it do what I require?
It will consist of enlarging, reducing size, fading (alpha).
Is this a straight forward thing? Are there reference code anywhere online that provide this information?
If anybody can also recommend any tutorials on this, I would be most grateful.
How To Actionscript A Certain Text Effect
i want to actionscript this one particular effect; check out <http://www.klausnielsen.dk/> and press "play" on the virtual tape-deck. this is done by simply coloring each letter differently in each frame, but it's too heavy and diffucult to edit and update.
anyone has an idea how to actionscript this please let me know
i'm using flash mx
klaus
Actionscript Text Color
I am trying to change the color of text created with actionscript using a textformat object, and all the properties seem to work except the color property. I set it like this:
txtFormat = new TextFormat();
txtformat.textColor = 0x006699;
obj.title.setTextFormat(txtFormat);
No matter waht hex value i put, it stays black... Any ideas?
dave
Please Help Verifying Text Through Actionscript
I need help bigtime!
I'm a newbie so you have to dumb down your explanations for me.
I am trying to create a simulation of a program at work. What I need to do is simulate a data entry type program. What I'm thinking is this...
The user types in a value in a text field and presses the Tab key. I want Flash to validate it as correct or incorrect and send it to another frame with feedback text or the next step.
How do I do this?
I currently use a program called Toolbook and am semi-familiar with scripting. They use a language called open script, which is very similar to actionscript. I am still learning though.
Any help would be completely appreciated.
Attaching Actionscript To Text
Thanks in advance to anyone who can help.
I have a scrolling text box and I want part of the text to link to another frame. It seems you cannot attach scripts to text however.
I am using Flash 5 on a Mac.
Attaching Actionscript To Text
Thanks in advance to anyone who can help.
I have a scrolling text box and I want part of the text to link to another frame. It seems you cannot attach scripts to text however.
I am using Flash 5 on a Mac.
Actionscript // Text Colour
Does anyone know if it is possble to set text colour in actionscript. I am pulling news text in dynamically and I would like to specify that the headline is a different colour than the body.
Has anyone got any ideas?
Text Scrolling With Actionscript
I'm having a problem with text scrolling with actionscript. I downloaded an FLA from flashkit (http://www.flashkit.com/movies/Scri...ndex.php?chk=no) and I did everything that the auther of the fla did and mine doesn't work. I can't get into contact with this guy and I'm running out of time. can anybody help me?
I've attached my FLA
Dynamic Text And Actionscript
Hi, I was wondering if anybody had any ideas how to solve a problem I am having.
I am trying to create a movieclip that will have some images in it and some dynamic text which I will import in to another movie.
I have created a movie with three frames
1. A picture
2. Another picture and a dynamic text field (dynText)
3. Another picture and the dynamic text field (dynText)
on frame 2 I have the following code:
loadVariablesNum("Text.txt ", 0);
If I run the movie it works fine, the dynamic text field shows the text from the file. If I export the movie and run the .swf file it works fine.
When I import the .swf file into my new movie it doesn't work. The drawings show up but no text. If I click on the movieclip to show all its frames the dynamic text fields aren't even in the movie and the actionscript is gone too, all I have is three frames with a drawing on each.
I have tried embedding the text in dynamic text, I have converted the drawing and text field to a symbol movieclip and button and nothing has worked, I still always end up with a movieclip with the missing actionscript and dynamic text fields, but it still works jsut running the .swf file.
Any ideas?
Thanks, Laura
Small Text Actionscript
B"H
i am using flash mx 2003 and i have a problem viewing the actionscript!
it is too small to read - i only have this problem with macromedia studio mx 2003 (mx 2004 doesn't have this problem)
how can i fix this problem (i alreadly tried changing my res.)
Yechi HaMelech
Moshiach Now
p.s. is it worth upgrading to 2004 and what about pro - is it worth it?
Animating Text With Actionscript
Hi pals.
I'm wondering how to animate a big volume of text with actionscript. I know that you can do that using AS but Im not a programmer (I'm actually a designer).
The idea is that I want to animate any character but if I do this manually it could takes years...
Any ideas to get this?
Please help.
...
Load Text ActionScript
I have a site - and 4 buttons. What actionscript would I use, if whn you click on a button text (loads) displays in a - text area I have made in the site.
What I'm saying is I have an area for text but each button you click
ex. About us - loads - About us text in that area - and contacts would load - contact info in that area - on the site. - but you can move back and forth across any button. Does that make sense.
What do I do?
Thanks for your time and help.
JT
TX
|