3 Replies Latest reply on Nov 12, 2006 10:51 PM by jpwrunyan

    Using SWC's during development

    jpwrunyan Level 1
      Right now I am part of a team that is making a base framework for a single Flex application. When the framework is complete, less experience programmers will make the actual screens for the application using the standard components and architecture we have made. We want to encapsulate the framework into an .swc so that the developers aren't tempted to modify the source or otherwise meddle with the framework (that is our job). I have made an .swc and registered it with a project just to see how this will go (all using Flex Builder) but am extremely distraught to see that there are no code hints for the classes contained in the .swc. I can still access them and use them and compile a sample application with them, but FlexBuilder doesn't acknowledge them the way it did when it was just raw source code. I have read the docs and they are heavily bent towards preaching RSL--but we do NOT want to use RSL. What am I doing wrong? Surely there is a way to register the .swc to be used in place of source code (.as and .mxml) in Flex Builder, right?

      Are there any tutorials that deal specifically with Flex Builder?
        • 1. Re: Using SWC's during development
          JeffreyGong Level 1
          How did you register your swc? I just simply put my swc under the library path and it is under the folder "Custom" right away in the tab "Components" if Flex Builder is in "Design" mode. Use it like other existing components there. Code hints are there too.

          Did you create your swc as a "Flex Library Project"?

          • 2. Using SWC's during development
            jpwrunyan Level 1

            Originally posted by: JeffreyGong
            Did you create your swc as a "Flex Library Project"?


            Hi, thanks for the reply.
            Yes I created it using the "Flex Library Project"... I couldn't see any other way to create the swc in FlexBuilder.
            I then copied the .swc file to a template project and implemented it via "Properties"->"Flex Build Path"-> "Library Path" -> "Add SWC".
            Since it is in the actual project folder, the path was simply: "ApplicationFramework.swc".

            I have only used SWC before with Flex 1.5 which was basically the same as Flex 2.0 data services. I am not too savvy with the new implementation (before I made .swc's in Flash IDE).

            Currently, we are not using FDS, just the SDK and Flex Builder. I can't help but suspect you are using the FDS? Would this problem be the difference between using the "Basic" project and the "Flex Data Services" project in Flex Builder?
            • 3. Re: Using SWC's during development
              jpwrunyan Level 1
              Ok, for some reason I got it to work better now by not moving the .swc file from the library project's /bin folder. The components all show up and etc. Not sure what I will have to do when I try sending the actual .swc file to the development team. Where should they put it, etc? I would have thought that the physical location of the .swc should be the root folder of the application... but I guess it doesn't matter?