Tracking Forums, Newsgroups, Maling Lists
Home Scripts Tutorials Tracker Forums
  Advanced Search
  HOME    TRACKER    Flash




MX 2004 TextArea Component



I'm pulling in some XML to appear in the MX 2004 textArea component. No problems there. What I need to know is how to make the text in the component appeare as embeded font outlines (softer rather than sharp, like it does in a static text box). I've tried using actionscript to define the components style, but no dice on the font outlines.

Any ideas?



FlashKit > Flash Help > Flash ActionScript
Posted on: 05-18-2004, 02:20 AM


View Complete Forum Thread with Replies

See Related Forum Messages: Follow the Links Below to View Complete Thread

MX 2004 TextArea Component
Does anyone know how to load an external .txt or .html file into the textArea component found in Flash MX 2004, or do I have to load it into a Dynamic Text Box?

Using The TextArea Component In Flash MX 2004 ?
Can someone please help me with this. All I want to do is populate the new textArea component in Flash Mx 2004 with an external file, using loadVariables("filename.txt", this),
where "this" is the name for the textArea component, right?

bottom line: how can I use loadVariables or something similar to dynamically fill in a textArea component box???

any tutorials out there yet on this??

TextArea Component Problem (MX 2004)
I have a site, and its broken up into seperate swf's, each being a page of the site. I have one main swf that initially loads the home swf and then the nav takes over from there.

My problem is that on the bios page (About me --> Biography) I have a TextArea. When I test the bio swf on its own it works fine. But when I test it by using the main swf and then loading the bio swf into it there are problems. When you hit the up arrow of the TextArea scoll bar, it jumps to the bottom. I don't know why. Can someone help me. I have attached the files so you can take a look. Just run the main swf and then navigate to the biography page.

Thanks!!

Scrolling Text With MX 2004 TextArea Component
Ok, so I know how to scroll text with the new TextArea component in MX 2004, but does anyone know if it's possible to import an external text file into the textArea component?

Change Font And Color In TextArea Component (MX 2004)
Hi,

How can I change the font, color and size etc. of text displayed in a TextArea component (MX 2004)? Is it only possible with a style sheet?

Thanx!

Help With TextArea Component Calling Javascript From Link In TextArea
Can anyone help me?
I have a TextArea Component that gets populated from a XML. I have the text with links and I want to be able to click on the link and call my javascript on my page. Can I do this? of what will I need to do to accomplish this. if you can provide an example that would be great.
Thanks in advanced

Content To Appear In Textarea Component Based Off Of ComboBox Component Selection?
Hello all:

I have a comboBox component with different values like so:

1-10
11-19
ETC.

Depending on what value is chosen from the comboBox, a certain value needs to appear in the text area. Do I need to use a listener for this? If not, any input would be appreciated. Thanks!

JPearson311

TextArea Vs ScrollBar & Mx Vs MX 2004
Hello
In flash mx 6- you could load variables into a text field and you could add a scrollBar but in Flash mx 2004 I cannot do that but I found that textArea is similar but I dont know how to loadvariables into it could you give me a hand please?

Thanks in advance

Textarea In MX 2004 With PHP And MySQL
I'm working on a form in Flash that I have successfully been able to connect to a PHP file that sends to a MySQL db, then another PHP file that displays the db data.

How can I connect the textarea component with my "comments" field in my db?  It's not as simple as an input text line that has a 'var' that corresponds to a variable in the submitting PHP file...

Any easy way to give that textarea a variable?

Thanks.

Flash MX 2004 TextArea Problem
Hello,
I have a problem with Flash MX TextArea component. I have a flash movie called "main". I am loading another movie inside "main" movie. Let's call the loaded movie "bioMovie". Inside the "bioMovie" there is a TextArea component that loads the text from a txt file. If I publish the bioMovie by itself the TextArea works just fine. However, when I run the bioMovie then I get the TextArea and the text in it fine until I start scrolling. When I scroll the text then the text becomes highlighted and the moment I let go with the mouse it goes to the bottom of the text. Does anyone know what Am I doing wrong?
Thank you very much for the help.
Ivan

Flash MX 2004 TextArea Problem
Hello,
I have a problem with Flash MX TextArea component. I have a flash movie called "main". I am loading another movie inside "main" movie. Let's call the loaded movie "bioMovie". Inside the "bioMovie" there is a TextArea component that loads the text from a txt file. If I publish the bioMovie by itself the TextArea works just fine. However, when I run the bioMovie then I get the TextArea and the text in it fine until I start scrolling. When I scroll the text then the text becomes highlighted and the moment I let go with the mouse it goes to the bottom of the text. Does anyone know what Am I doing wrong?
Thank you very much for the help.
Ivan

Change Color Of Scrollbar By Textarea (FL 2004))
How change color of scrollbar by Textarea?

Thanks

I tried to use:

mytextArea.setStyle("scrollTrackColor", "0x2CC5FE");

But it not works by me

MX 2004, UIScrollBar, TextArea, DoLater And Margins
Hello,

I am trying to make a chat client in MX 2004. (I have to use MX 2004, because I need the DataGrid component).

Problem:

I need a text box that displays chat messages. This text box must have a scrollbar that will auto-scroll to the bottom when new chat messages arrive in the text box.

Solution #1:

Paste the old MX ScrollBar component into the MX 2004 IDE. This scrollbar works perfectly with a simple dynamic text field. The problem is that it is skinned in the old gray style, and does not match the new DataGrid skin.

Solution #2:

Use a dynamic text field and the new UIScrollBar. This doesn't work because UIScrollBar will not auto-scroll to the bottom properly. (This is a documented bug, I believe).

Solution #3:

Use a TextArea with built-in scroll bar. This works by circumventing the above bug via doLater(). The problem with this is that the chat message text is too close to the left side of the TextArea, and I can not find a margin parameter.


Does anyone have any suggestions?

Format External Data In Flash 2004 TextArea
I want to pull external data into a Flash 2004 Pro textArea. The data will need some formatting. Specifically line breaks, Bold Text, and Paragraph Breaks. What are my options for doing this. I have heard that html tags are whacko in 2004 pro.

Thanks for your help

Finally... How To Use MX 2004 TextArea To Create Dynamic Scrolling Text Fields
After working on this for far longer than I should have, I've finally figure out how to use MX 2004's TextArea component to display dynamically loaded text strings from our CF server.

In the interest of saving everyone else time, expense and grief, here's what I did.

(1) Drag the TextArea component onto your movie.
(2) Use the Properties inspector's properties tab to set the width and height values of the text field.
(3) Give the TextArea an instance name. I used "comment".
(4) Switch the Properties inspector to the parameter mode and edit these fields as appropriate. I changed HTML to true, EDIT to false, WORDWRAP to false, etc. Be sure to leave TEXT alone.
(5) Insert a second layer in the movie and open the ACTION panel and insert the code you're going to use to pull the text string(data) from your server.

Here's my code:
code:
var colist = new LoadVars();
dataurl = "http://www.mycompany.com/flash/quote.cfm?co_name=Cod";
colist.load(dataurl);
attachMovie("loadbar","loadbar",9);
loadbar._x=5;
loadbar._y=175;
colist.onLoad = function() {
removeMovieClip(loadbar);
comment.text = colist.company_list;
}

I load the "loadbar" movie to indicate a search is being made and to give the server time to return the data. Once the data is loaded, I remove the loadbar movie.

What this CF query does is look for companies whose names include the phrase or word "Cod". This of course would usually be a variable input by the user, but for test purposes I hard-coded it.

When I test the movie, I get back a selectable list of company names and their respective stock symbols in a scrollable text window with both vertical and horizontal scrollbars.

I hope this helps reduce the frustration I felt trying to figure out how to make this all work.

Now to move on to customizing the component!

TextArea Component
I was able to disable the borders of the textArea component using the
following action script

textArea.setStyle("borderStyle", "none");

But this created a new problem. Now when I select the text or hi the
scroll bar I get agreen "glow" or highlite where the borders would be.

Anybody have any suggestions


...may you see that on http://www.agenciax.com/clientes/lima_netto/ , when this load click on "escritorio" button on top menu in portuguese version.

Textarea Component Help
is it possible to make the background transparent?

TextArea Component
I have a dynamic textArea component. When I load new text into it, the scrollbar stays where-ever it was last positioned - is there a way to make it return to the top everytime? Does it ususally return to the top for everyone else?

Thanks
Jessica

Textarea Component
Hi

I have a movie that contains a textarea component. I am loadind in text from a database via php.

If I run the movie on its own it works perfect. But if I load it into an empty movie clip or a level the scroll bar goes erratic and for some reason when you click on the scroll bar the text inside gets selected.

I have tried to use a plain textbox but cannot get the text formatted using html as with the textarea, code below.

var lv = new LoadVars();
lv.onLoad = function(ok) {
if (ok) {
var i = 0;
while (this["id" + i] != undefined) {
noticeboard_txt.text +="<br><br><br><b><u>"+this["titles"+i]+"</u><br><br></b>" +this["news"+i]+"<br>" +"<b>"+this["author"+i]+"<br>"+this["date"+i];

i++
}
}
}
lv.load("noticeboard.php");
// Make background color transparent
noticeboard_txt.depthChild0._alpha=0

Thanks for any help.

TextArea Component Help
Don't know how to insert line break in 'text' field of 'Parameters'.

TextArea Component
Hi,
I was just wondering if it is possible to load a .txt file into a TextArea component? I 've tried this:

Code:
loadtextContent = new LoadVars();

loadtextContent.load("Bio.txt");

this.BioText.text = loadtextContent;
but it doesn't work. Could anyone help?

Thanks
Jay

TextArea Component In _mc
Is there an issue with using a textArea or textInput within a movie clip?

i am placing a textArea onto the stage of a mc (which is then placed on the timline of my scene )and then trying to import text from a *.txt file into it. I have tried various actionscript codes with both plain text (not favoured) html text and XML text files (preffered as I wish to formatt the text) without any luck.

I debug the actionscripts without any errors being generated but the text will not appear in the textArea component...or the component even be viewed when the movie is tested or previewed in a browser???

complete newbie so be gentle please

TextArea Component
I just noticed this is a similar title to another post I made, but rest assured the content is different.

If you go to:

http://www.westerndaytraders.com

You can see that there is a Flash TextArea component that is fetching posts from the Forum (through XML formatted by PHP). To view the XML that Flash is using, go here and view source. Perfectly formatted XML.

Now, as you probably noticed from the main page, the formatting in the news box is way off. The paragraph spacing more specifically is more than double what it should be. If you look on the forum in the 'news' section, you can view the post and see that it is formatted properly.

If anyone has some insight, please let me know.

Oh, before I forget, here is the code on the TextArea (well, not on it, but pertaining to it):


PHP Code:



txtShows.setStyle("borderStyle", "none");
txtShows.setStyle("scrollTrackColor", "0xFCF69A");
txtShows.setStyle("buttonColor", "0xFCF69A");
txtShows.html = true;


//LOAD THE XML DOCUMENT FOR NEWS
_root.onLoad = load_xml();

function load_xml() {
    System.useCodepage = true;
    myXML = new XML();
    myXML.ignoreWhite = true;
    myXML.onLoad = function(success) {
        //CALL SHOW_NEWS FUNCTION
        show_shows();
    };
    //LOCATION OF XML DOC
    myXML.load("admin/news_puller.php");
}


function show_shows() {
    for(var i=0; i<myXML.firstChild.childNodes.length; i++) {
    //RENAME CHILDNODES WITH VARIABLES
    date = myXML.firstChild.childNodes[i].childNodes[0].firstChild;
    subject = myXML.firstChild.childNodes[i].childNodes[1].firstChild;
    user = myXML.firstChild.childNodes[i].childNodes[2].firstChild;
    userurl = myXML.firstChild.childNodes[i].childNodes[3].firstChild;
    news = myXML.firstChild.childNodes[i].childNodes[4].firstChild;
    comments = myXML.firstChild.childNodes[i].childNodes[5].firstChild;
    url = myXML.firstChild.childNodes[i].childNodes[6].firstChild;

    //EMBED XML INFO INTO NEWS_CONTENT TEXT AREA
    txtShows.text += "<font family='verdana' size='12pt'><b>"+subject+"</b></font><font size='10pt'><br>Posted By </font><font color='#336699' size='10pt' family='verdana'><u><a href='"+userurl+"' target='_blank'>"+user+"</a></u></font><font family='verdana' size='10pt'> on "+date+"</font><br><font family='verdana' size='13pt'><pre>"+news+"</pre></font><br><font color='#336699' size='10pt' family='verdana'><u><a href='"+url+"' target='_parent'>"+comments+"</a></u></font><br><br>";
    }
    }

[F8] Please Help W/ TextArea Component
i've searched this forum but cannot seem to find a relevant solution to customize the textArea's scroll bar.

any tutorials on how to customize the textArea's scroll bar will be greatly appreciated.

thank you

TextArea Component
Hi,

I have used TextArea component in flash (mx/2004) by using built in components of flash. I have set html to true for the html text to be displayed by XML. But I think only some of the tags are supported with this component. Tags like table and other supporting tags are not displayed properly in textArea component. Then what could be the solution for the same.

I have tried to put the following text -

my_textArea.text ="<table border='2' cellspacing='5' cellpadding='5'><tr><td>first</td><td>second</td></tr></table>"

but table with border is not diplayed at all. Kindly help me in the same as early as possible.

Thanks in advance,
Shreeram

TextArea Component CS3
I've searched the net, joined Safaribooksonline, bought Colin Moocks Essential Actionscript 3.0 & Actio0nscript 3.0 cookbook and nowhere can I find out how to apply an imported css stylesheet to a CS3 TextArea component. I used to do this all the time in AS2 and it worked a treat. The only help I can find in the CS3 authoring tool and in live docs relates to AS2 which causes errors in my AS3 class. I'm building a custom TextAreaManager class for my general use. If anyone knows how to do it please let me know.
Thanks
Dave Towers

TextArea Component AS3
I'm having trouble both working out or finding out how to apply an imported css file to the CS3 TextArea component. I've frequently done this in AS2 using Flash 8, but that code no longer works. If anyone knows could you please let me know. Here's the AS2 code I've used previously:

private function loadCss(){
var myStyle = new TextField.StyleSheet();
myStyle.load(this.CssPath+".css"); // the CssPath variable here was supplied within an object passed through to the constructor
textArea.styleSheet = myStyle;
loadXml();
}

TextArea Component
Is it possible to use a TextFormat object to set the text format of a text area component? Thanks .

TextArea Component
Hi, how can I change the enable chars of a TextArea Component?
Thx!

TextArea Component
I have inserted a TextArea component and i can add text normally by changing it in the parameters tab. but i was wondering if anyone knew the code so i can make it show and input text field ? (call a .txt file in to the TextArea component) is this possible if so can u please show me the script thanks alot. Jimmy

TextArea Component Help
Hello, I'm importing text into a TextArea component and it all works fine and dandy. Though I want the textarea to not form a scrollbar but to actually just keep adjusting its height so there is never a scrollbar. I looked through all the properties and I have no idea what to test for to see if there is a scrollbar.
can anyone help?

Textarea Component
Hi,
I am using the TextArea component (MX2004).  I have set the html setting to true and have entered my text.  However, despite numerous attempts with different bits of code, I can’t get the font to be veranda, 10pt and red.  I  thought this would be a straightforward process.  Does anyone have any suggestions?
Thank you for you time and help
rich


TextArea Component
hey is there any way that i can make the background of a textArea component transparent or invisible?

TextArea Component
Last edited by swaze : 2006-01-28 at 10:10.
























I have two TextArea's in a movie, they're both attached to the same style sheet. Why does one work and one not? The TextArea for the FAQ's (link at the bottom of the screen) works. But the CSS for the TextArea on the 'About Us' page does not work. They both use the exact same code to link to the CSS.

This is the About page:

myStyle = new TextField.StyleSheet();
myStyle.load("flash/msjenkins.css");
_root.yellow.About.styleSheet = myStyle;

This is the FAQ page:

myStyle = new TextField.StyleSheet();
myStyle.load("flash/msjenkins.css");
_root.faqf.TextHolder.styleSheet = myStyle;

Does anyone know why the About page wouldn't work?

UI Component TextArea And CSS
Hi There

Does anybody know, if I can use CSS in the TextArea Component?
If yes, how?
I know that this should work with TextField, but I prefer the TextArea Component because of the scrollbar stuff.

Cheers

}-^°>

MX2004 + TextArea Component
I've got a flash animation where i load text in from a txtfile by using

"loadVariables("part1.txt", "_root");"

it works when i put it into a dynamic text box... but unfortunately it has more text than can fit, so i need a scroller... HOW CAN I USE the "TEXTAREA" component to read in information from a text File...


PLEASE HELP... THIS IS URGENT

TextArea Component Fontsize
How can i set the font size of one single component like the textarea
component ?

I can't seem to set the font size

With globalstyle i can but then all components get that size


thanx in advange...

Assenoost

Flashmx2004 Textarea Component
Hi,

I am using the textarea component, where you put text into the box with myTextArea.text ="blah" this works fine but I want to put the contents of a text file into the textarea.

I have a text file with htmlTXT= blahhh which loads fine into a standard text box from the flash toolbar when i have defined a variable for it to contain with the same htmlTXT name.

So the question is how do I load this variable so I can put it inside the textarea component, I have tried but keep getting undefined in the text area.

liam (tearing my hair out)

TextArea Component Characters?
I'm using MX 2004 Pro. How can I set the characters that are displayed in a text area component? I have some text loaded in dynamically but special characters like % don't show up. Any ideas?

Loading PHP Into A TextArea Component
Ok I've made a working blog using PHP, MySQL, and Flash MX 04 Pro. Right now my blog displays in a dynamic text box with the var "content". I would like to make it appear in a textArea component because then in the future I'll be able to upload pictures and .swf's for display inside my blog. Can anyone help me figure out how to display the information in a textArea component? I would greatly appreciate it.
I've attached a zip with all the necessary files, including the dump SQL for the database if you want to use it. Thanks all.

TextArea Component Gone Berserk
Ok I've got a textArea component on the stage. I have a PHP script that returns data from a MySQL database formated and sent to Flash as the variable "content". I couldn't figure out how to assign a textArea a variable name, unfortunately it's not as easy as with a dynamic text field, so I created my loadVars function and pointed it at the instance of my textArea component. For the first time it worked....sort of. I can see the text but there's all sorts of symbols breaking it up and screwing up the format. Check out what I mean....Blog . Anyone know how to make this work? Here's a link to my site where you can download all the necessary files to work with, I couldn't attach them cause they were too big.download link

TextArea Component: Border
Using FLASH MX PRO 2004

ok i've figured out how to change the backround color, and change the text color (using CSS) with this component...

now how do I change the color of the BORDER around the text?? or take it off even??

i've tried the help files within flash
(textArea.border= "false")
and all variations of this!
textArea.setStyle("borderColor", "black");
and all variations of this as well...

i can't figure this out, somebody help me out.

thanks

TextArea Component Question
How do I make the background transparent? I know that if type in myTA._alpha=0 it'll make it transparent but then the scroll bar disappears too.

Textarea Component Problems
Hi there,

I've just made the switch to MX 2004 and so far I'm distinctly underwhelmed by the new version; within minutes I have run into problems with the new v2 textarea component.

My problem is this:
I'm having trouble embedding fonts for the textarea component in my movie. Does amyone know how to do this? (And not embedding fonts for ordinary textfields as that is simple in properties or actionscript)

To give some context this is what I'm building:
I'm building a Q&A app which loads questions from an XML doc, these questions contain very basic html formatting (bold, italic, paragraph).

I built the original version of my app in MX. In MX I had multi-line textfields with scrollbars attached, fonts (verdana) embeded turned on and unused blank textfields off stage to embed bold and italic versions of the font. The result of this was a textfield with anti-aliased verdana text and html formating.

It is this that I want to re-create in MX 2004 with textarea component.

Any help would be much appreciated.

TextArea Component Problem
Hi,

Flash MX 2004. Using the TextArea component looked simple enough yet I'm having a problem with this. If I create a new movie, place an instance of the TextArea on the stage, name the instance "Comments" then in the properties inspector enter some text in the "text" field (Parameters) - then preview it, everything works.

But when I do this again and place the TextArea inside an MC, then preview my file, it dissapears...... What am I doing wrong?

Please help,

Thanks

:-)

Luke

TextArea Component Question
I have a TextArea component loading external text:


Code:
description.textField.selectable = false

description.setStyle("borderStyle", "none");

description.depthChild0._alpha = 0;

myStyle = new TextField.StyleSheet();
myStyle.load("port/home_work/hometext.css");
this.description.styleSheet = myStyle;
thisText = new LoadVars();
thisText.load("port/home_work/hometext1.txt");
thisText.onLoad = function(success)
{
if(success)
{
description.text = thisText.myText;
}
}


Is there a way to turn off the thin green line that appears when the TextArea is clicked on and becomes in focus? Not sure why the TextArea is still able to be selected since the "selectable = false" code exists.

Thanks much!

Flash Textarea Component Help
Few problems I have with the textarea component, and I need help real quick pleeease?

Number 1. Is there any way I can load a large amount of text stored in a TXT file into the box on the click of a button?
Number 2. Does textarea support scroll bars?
Number 3. Can I alter the colours of the textarea?

Please pelase please help!

Styles For TextArea Component
Hi everyone,

Can any one tell me why the myTextArea.setStyle("color", 0xFFFFFF), that supposed to change default color of text does not work for the TextArea component in 2004? I'm using actionscript 2.0.

Actualy the only property that works for TextArea is the "backround"... For some reason "color" property works for ListBox on the same timeline... And yes, I did double checked that I did not misspelled the instance name of the component...

Thanks for your time,
Peter

TextArea Component Difficulty
I’ve stayed clear of Components for as long as i can because i find them really hard to customise but I’ve realised there useful and had another go.

so...I’m trying to customise a TextArea. I managed to do the scrollbar by importing appropriate things into the library and changing them. What I really want is a completely invisible TextArea (not including the scroll bar and text of course). Can anyone tell me the best way of doing that?

If not i would like to convert RGB colours to the colour code used when using styles eg '0x848384'.

thanks you your help.

Copyright © 2005-08 www.BigResource.com, All rights reserved