Hi guys
I have four different components in views folder and i have a view stack in
which those components are imported like this
<mx:ViewStack id="vs" resizeToContent="true" selectedIndex="1">
<views:About/>
<views:Restaurant/>
<views:Home />
<views:Contact/>
<views:Events/>
</mx:ViewStack>
and in About componet i have button i want when i click on that button
control goes to component called Home...i have tried like this
This is in About
<mx:Button label="GoToHome" click="handleClick(event)"/>
<mx:Script>
<![CDATA[
*import* MenuDemo; // Main Application in view stack is there
*public* *var* menuObj:MenuDemo = *new* MenuDemo();
*public* *function* handleClick(event:MouseEvent):*void*{
menuObj.vs.selectedIndex=2;
}
]]>
But it is showing null object ref... How can i do this ..Help me
</mx:Script>
--
You received this message because you are subscribed to the Google Groups "Flex
India Community" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/flex_india?hl=en.