Thanks, John!
I used your second example but I get the following error on the button: 1067: Implicit coercion of a value of type String to an unrelated type flash.net:URLRequest. ________________________________ From: [email protected] [mailto:[email protected]] On Behalf Of John Waggener Sent: Wednesday, February 04, 2009 9:46 AM To: [email protected] Subject: Re: [AFFUG Discuss] Exiting an Application and Calling a URL To call a link in Flex/Flash, you utilize URLRequest and navigateToURL The syntax looks like this: import flash.net.URLRequest; import flash.net.navigateToURL; private function goToGoogle():void{ navigateToURL(new URLRequest("http://www.google.com")); } more generally... private function linkToURL(resource:String):Void { navigateToURL(new URLRequest(resource)); } <mx:Button label="Exit" click="navigateToURL('http://www.google.com')"/> On Wed, Feb 4, 2009 at 9:28 AM, Frank Griffin <[email protected]> wrote: I have an "Exit" button that I need to close the application and call a URL. What is the proper syntax for this? I get an error with the following code: 1084: Syntax error: expecting identifier before rightbrace. <mx:HBox borderStyle="solid" paddingTop="10" paddingBottom="10" paddingLeft="10" paddingRight="10"> <mx:Button label="View" click="myViewStack.selectedChild=ViewOnly;"/> <mx:Button label="Edit" click="myViewStack.selectedChild=EditView;"/> <mx:Button label="Delete"/> <mx:Button label="Exit" click="http://www.google.com;"/> </mx:HBox> Thanks, Frank ------------------------------------------------------------- To unsubscribe from this list, simply email the list with unsubscribe in the subject line For more info, see http://www.affug.com Archive @ http://www.mail-archive.com/discussion%40affug.com/ List hosted by FusionLink <http://www.fusionlink.com> ------------------------------------------------------------- -- Johnny Waggener Software Developer Multicast Media 678-592-2650 ------------------------------------------------------------- To unsubscribe from this list, simply email the list with unsubscribe in the subject line For more info, see http://www.affug.com Archive @ http://www.mail-archive.com/discussion%40affug.com/ List hosted by http://www.fusionlink.com -------------------------------------------------------------
