4 Replies Latest reply on Oct 6, 2006 3:43 PM by Newsgroup_User

    Loader Component

    bcounts Level 1
      Is it possible to load a picture link from a TXT file using the Loader Component.

      Can someone walk me through this and show me the code.

      Thanks in advance!
        • 1. Re: Loader Component
          crazyjoemilan Level 2
          of course. All you do when you import data from a .txt file is import variables. (or create variables by importing the entire file).

          in you .txt file, you can write

          &link1=http://www.13studios.com&link2=http://www.13studios.com/joe

          the & symbol tells flash a new variable is a-commin'. Then just use the LoadVars() .load() method to import the .txt file, assign the variables to buttons, and you can have the buttons be links using those variables.

          Make sense?
          • 2. Re: Loader Component
            bcounts Level 1
            I am sorry - I might have not been clear about what I am using.

            I am using the Loader Compnent from the compnents panel.

            I want to tell that component to load a picture from a folder on my server through a TXT file making updating the picture simple.

            I need the code to tell the component to look to the TXT file for the link where the image is held.
            • 3. Re: Loader Component
              crazyjoemilan Level 2
              Oh I'm sorry. I generally hand build that stuff. I can help you if you'd like to do that, but if you want to just use a canned component, I'm sure they have documentation around to help you out. (ie- I don't know)
              • 4. Re: Loader Component
                Level 7
                Do as Mr. Helpy explains and then use this code below with the instance name
                of your loader component as "loader":

                loader.contentPath = link1;
                loader.load();


                --

                Dan Mode
                --> Adobe Community Expert
                *Flash Helps* http://www.smithmediafusion.com/blog/?cat=11
                *THE online Radio* http://www.tornadostream.com
                *Must Read* http://www.smithmediafusion.com/blog



                "Mr Helpy mcHelpson" <webforumsuser@macromedia.com> wrote in message
                news:eg68um$g5f$1@forums.macromedia.com...
                > Oh I'm sorry. I generally hand build that stuff. I can help you if you'd
                > like
                > to do that, but if you want to just use a canned component, I'm sure they
                > have
                > documentation around to help you out. (ie- I don't know)
                >