How to initialize editor?

580
3
Jump to solution
07-04-2012 10:08 AM
AmandaHutsel
New Contributor
I'm using the sample code for the Defualt Editor.  In the <Application> tag there is the line  

initialize="application1_initializeHandler(event)"

I keep getting a debugging message when I start my application and my templates do not show up as well.  I am using a view stacks method for showing several different maps, and the edit view is on only one of the views.
This is the error that I get[ATTACH=CONFIG]15770[/ATTACH]

I think that I may need to move the initialize="application1_initializeHandler(event)" line of code, but I don't know to where.  Any ideas?
Tags (2)
0 Kudos
1 Solution

Accepted Solutions
KenBuja
MVP Esteemed Contributor
This is something that's bitten me when using ViewStacks. You have to set the the ViewStack's creationPolicy to "all", otherwise, many things that are contained in the stack won't be created at startup. From the help:

Containers with multiple views, such as the ViewStack and Accordion, do  not immediately create all of their descendants, but only those  descendants that are visible in the initial view. Flex defers the  instantiation of descendants that are not initially visible until the  user navigates to a view that contains them.

View solution in original post

0 Kudos
3 Replies
KenBuja
MVP Esteemed Contributor
This is something that's bitten me when using ViewStacks. You have to set the the ViewStack's creationPolicy to "all", otherwise, many things that are contained in the stack won't be created at startup. From the help:

Containers with multiple views, such as the ViewStack and Accordion, do  not immediately create all of their descendants, but only those  descendants that are visible in the initial view. Flex defers the  instantiation of descendants that are not initially visible until the  user navigates to a view that contains them.
0 Kudos
AmandaHutsel
New Contributor
Thanks Ken, that solved the problem.
0 Kudos
KenBuja
MVP Esteemed Contributor
nevermind...
0 Kudos