1 Reply Latest reply on Sep 6, 2007 4:53 AM by phlax

    Flex Builder 2 overwrites HTML wrapper

      Hi everybody,

      I pass values to my app using flashvars, which works pretty well. But Flash Bulder 2 overwrites the html wrapper file with the flashvars at every build.

      If I switch off the setting "Generate HTML wrapper file", then the wrapper will not be overwritten anymore, but then I can't start in the debug mode, which is terrible... Funnily enough, the Flex Builder tries to start the SWF file with the Real Player then (without the wrapper), which doesn't work out of course.

      Here my questions:
      How can I tell Flex Builder 2 to transfer the flashvars in the html wrapper also to the wrapper located in the /bin folder? After each build those are overwritten.

      How can I run my app in debug mode with switched off option "Generate HTML wrapper file", and with the use of the existing html wrapper files, in which my flashvars are located?

        • 1. Re: Flex Builder 2 overwrites HTML wrapper
          phlax Level 1
          I found out what I did wrong... here my answers to my questions to share it with possible imitators ;)

          To change a wrapping html which is created and updated by Flex Builder, it is important to edit the /html-template/index.template.html, and not the index.html located in the root folder of the project, since this will be overwritten each time a build happens.

          Flash vars in the html should be placed not only in the html section, but also in the JavaScript section, which will be used by default from the browser. To locate the right place in the JS, just search for "flashvars", and add the parameters to the values of this key.