2 Replies Latest reply on Apr 7, 2010 3:44 PM by ThiaKPSU

    Dynamic Text

    ThiaKPSU

      OK - so I know how to make Text Dynamic in Flash but I am having a hard time figuring out how to make it dynamic in Catalyst.

       

      I have looked through the properties area and don't see anything to make the text dynamic.

       

      Any help is appreciated!

       

      Thanks

       

      Thia

        • 1. Re: Dynamic Text
          Bear Travis Adobe Employee

          Hi Thia,

           

          How exactly would you like to use dynamic text in your project?

           

          You can't do this in Catalyst, but you can bring your .fxp into Builder for some quick modifications to get what you want.

           

          There are two basic options in Builder:

          1. Give your text field an id:

               Add the id to the text field <s:RichText id="myId" .../>

               From an ActionScript block you can set the text using myId.text = "my text"

          2. Bind the text value to a String variable.

               Add an ActionScript string variable such as public var myString:String;

               Bind the value of your text field to your string, which would look like <s:RichText text="{myString}"/>

               This way, whenever you set the value of myString, the change will be reflected in your RichText.

           

          Here are two pieces of documentation. The first is on binding variables, and the second is on loading data from outside files (in case you wanted to load your variables, from, say, a text file).

          http://livedocs.adobe.com/flex/3/html/help.html?content=databinding_8.html

          http://livedocs.adobe.com/flex/3/html/help.html?content=17_Networking_and_communications_3 .html

           

          -Bear

          • 2. Re: Dynamic Text
            ThiaKPSU Level 1

            Thanks for the info! I imported it into Flash Builder and then exported the file afterward and when I tried to open it in Flash Catalyst, it gave me an error that it could not open the file as it was created with a different version of Catalyst. I assume that part will be fixed on release.

             

            Its a good thing I always back things up before I try something like this! LOL.

             

            I am using my current project as my pitch for using Catalyst (when released) and Flash Builder for our Intranet as well as our distance learning application front-end. There are several things I like about Catalyst.

             

            My only complaint is that it is a little clunky - but I know that is a beta issue.

             

            There do seem to be more text issues I am coming across. (for static text while I wait to see what I can do with Flash Builder)

             

            I now have 5 states, with a tremendous amount of vector art on each. Now, when I try to copy/paste text or even try to change it in a new state - it will highlight the text, but it won't allow me to change the text. It won't paste it either. (I can tell it is copying as it shows up on clipboard).

             

            Glitch? It was working up until I stated Catalyst today.