In the following code the navigateToURL property is navigating to the same page which creates the refreshing of the page.
<? xml version = "1.0" encoding = "utf-8" ?> < mx:Application xmlns:mx = "http://www.adobe.com/2006/mxml" layout = "absolute" minWidth = "1024" applicationComplete = "init()" minHeight = "768" > < mx:Script > <![CDATA[ import flash.net.navigateToURL; import mx.controls.Alert; private function init():void { } protected function button1_clickHandler(event:MouseEvent):void { navigateToURL(new URLRequest("javascript:location.reload(true)"), "_self"); var urlRequest:URLRequest = new URLRequest(Application.application.url); navigateToURL(urlRequest,"_self"); } ]]> </ mx:Script > < mx:Button x = "187" y = "101" label = "Button" click = "button1_clickHandler(event)" /> </ mx:Application > |