3 Replies Latest reply on Jul 16, 2008 3:05 AM by Karl_Sigiscar_1971

    How do I add a library?

    goodespeler
      This may be a simple question, but I have downloaded a third-party library and I'd like to know how to add it to my flex app. so that I can use? I assume there's two parts, copying the files to the right location and including it somehow in the app. itself. How might I do that? Thank you! - Joshua
        • 1. Re: How do I add a library?
          EDendramis Level 1
          The files can be wherever you want. I am assuming it's an swc file, correct?
          Open Flex builder and under Project > Properties > Flex Build Path, Click on the Library Path Tab, then just click "Add SWC" and find your file! If you move the file, you will have to update this again.

          Also, SWCs are compiled into the project, so when/if you upload the project you will not need the swc file on the server.


          • 2. Re: How do I add a library?
            goodespeler Level 1
            Actually, it's broken down into a folder structure like:

            net:folder:helpers:file.as and another that is similar.

            Do I do the same thing even though their isn't a swc? And do I need to do anything special to use the added functionality in my script or can I just instantiate the new classes, etc?
            • 3. Re: How do I add a library?
              Karl_Sigiscar_1971

              You have two choices:

              - You put the library source folders directly under your project folder and you just use the classes as if they were yours.

              - Or you create a new library project in Flex, point to the library source folder, select the class files that should be part of the SWC then build the SWC. Then you can add the SWC to your project as EDendramis suggested.