1 Reply Latest reply on Sep 16, 2010 6:25 AM by jen1107

    flex 4 not supporting state component..?

    Ling's Level 1

      Hi all.,

      I have using state component in flex 4.

      but. error displayed

      State overrides may no longer be explicitly declared. The legacy states syntax has been deprecated



              <s:State name="expaneded">

                    <mx:AddChild position="lastChild">
                          <s:Label id="lbl_searchfield"   paddingLeft="30" text="Search Field" color="white"  />
                          <s:Label id="lbl_searchvalue"  paddingLeft="180" text="Search Value"  color="white" />
                          <s:Label id="lbl_searchflltext"  paddingLeft="270" text="Search FullText"  color="white" />


      how to solve this problem., any one help me..




        • 1. Re: flex 4 not supporting state component..?


          AddChild is deprecated in Flex 4. Instead use includeIn, that'll be an attribute of <s:Label> with value, "state_name".





          <s:State name="expaneded"/>







               <s:Label id="lbl_searchfield" paddingLeft="30" text="Search Field" color="white" includeIn="expaneded"/>



               <s:Label id="lbl_searchvalue" paddingLeft="180" text="Search Value" color="white" includeIn="expaneded"/>




               <s:Label id="lbl_searchflltext" paddingLeft="270" text="Search FullText" color="white" includeIn="expaneded"/>







          Check this out: