3 Replies Latest reply on Aug 26, 2011 7:52 AM by Amy Blankenship

    Getting a server going

    Jerry62712 Level 1

      I have a tomcat server installed in my flash builder plugin.  But when I run an application, it won't use the server.  Instead, it has the file come up in the browser.

       

      How do I get the application to use the server?

        • 1. Re: Getting a server going
          Vibhuti Gosavi(InfoCepts) Level 3

          Hi,

           

          First thing we need is to be sure we have “Server” view displayed (if not you go to Window > Other Views… and select Server from the tree).

          The first time you want to run a project you need to associate the project with the server – you do this only one time. You just right click inside the Flex application file and choose from the contextual menu Run As > Run on Server option:

          This command will open this little wizard (you select the previously defined server and then click “Finish”):

          After this the project gets compiled, the server is started and the project is deployed. At this point if you are looking inside the Server view you should be able to expand the Server node and see that a child exists with the same name as the project and the status of the server should be Started and Synchronized:

          Now every time you change something in your project as soon you build the project, the project is redeployed automatically. And when you want to see the Flex application you choose Run As > Flex Application (the default browser is opened with the Flex application inside). Also because the project is associated with the server you can use the top right buttons from the Server view to start / stop / debug / publish.

           

          Please see following link:

           

          http://corlan.org/2008/06/05/creating-a-combined-flexjava-project-in-flex-builder-wo-lcdsb lazeds/

           

          Thanks and Regards,

          -----------------------------------------------------------------------------------------

          Vibhuti Gosavi | vgosavi@infocepts.com | www.infocepts.com

          ------------------------------------------------------------------------------------------

          • 2. Re: Getting a server going
            Jerry62712 Level 1

            Thanks for the details.  I'll try to attach my screen shots.

             

            I have a Tomcat 6.0 server attached to my Flash builder.  As you can see in "ServerRunning.gif" it is started and synchronized.

             

            Under Window | Preferences I have the server as well.  As you can see in "preferences.gif" it is in the runtime environment.

             

            But when I try to run the application, as seen in "run.gif", using the Web Application, the server never sees the application like you had in "run_flex_app_3.png."

             

            BTW, you will see errors in the first screen print.  Those are scripts that I haven't updated to point to the components.  I moved the input form to one and the results display to another.  Naturally, I don't expect the application to work (do the calculations) until those are fixed, but I do expect the input form to display.

             

            Thanks for looking at it!

            • 3. Re: Getting a server going
              Amy Blankenship Level 4

              Errors will cause your project to fail to compile.  So if you have never successfully compiled it to your server, it will not display.

               

              HTH;

               

              Amy