hi this is the application <?xml version="1.0" encoding="utf-8"?> <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute" creationComplete="init()"> <mx:Script> <![CDATA[ import mx.controls.Alert; private var shaObj:Object private function clear():void { shaObj.clear(); main.selectedChild=one; } private function init():void { shaObj=SharedObject.getLocal("mySharedObject"); if((shaObj.data["u_Name"]!=null) && (shaObj.data["p_password"]!=null) && (shaObj.data["c_checkBox"]==true)) { u_Name.text=shaObj.data["u_Name"] p_password.text=shaObj.data["p_password"] main.selectedChild=two; //Alert.show(shaObj.data["c_checkBox"]); } } private function sO():void { if((u_Name!=null) && (p_password!=null)) { shaObj.data["u_Name"]=u_Name.text; shaObj.data["p_password"]=p_password.text; shaObj.data["c_checkBox"]=c_checkBox.selected; shaObj.flush(); main.selectedChild=two; } } ]]> </mx:Script> <mx:ViewStack id="main" width="540" height="340"> <mx:Canvas id="one"> <mx:Label x="89" y="87" text="Name"/> <mx:Label x="89" y="128" text="Password"/> <mx:TextInput x="229" y="85" id="u_Name"/> <mx:TextInput x="229" y="128" id="p_password"/> <mx:Button x="254" y="188" label="Button" click="sO()"/> <mx:CheckBox x="254" y="158" id="c_checkBox" label="Remember"/> </mx:Canvas> <mx:Canvas id="two"> <mx:Label x="112" y="58" text="In success"/> <mx:TextInput x="76" y="105"/> <mx:Button x="110" y="135" label="Button" click="clear()"/> </mx:Canvas> </mx:ViewStack> </mx:Application>
when you run you can see name pasword screen login page if you check Remember and click button it will go to second screen in second screen if you refresh it will not come to login page because you made the check Remember if you click the Button in second page it will come to login page Hope this will help you -- Karthik.k Mobile - +91-9894991640 http://kkarthikresume.blogspot.com/ On Tue, May 26, 2009 at 11:02 AM, Navien Amirtharaj < navien.amirtha...@gmail.com> wrote: > Hi Mr.Karthik, > > Thank u for ur reply. i need some small examples. i use that shared > object but still i'm facing the same problem... plz help me to short out > this problem... > > Thanks and Regards, > > Navien > > > > > > > --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Flex India Community" group. To post to this group, send email to flex_india@googlegroups.com To unsubscribe from this group, send email to flex_india+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/flex_india?hl=en -~----------~----~----~----~------~----~------~--~---