![]() |
![]() |
||||||
|
|||||||
| Tags: browser |
![]() |
|
|||
|
Hi All,
I'm new to flex.I have a doubt regarding "How to open the new browser window when i click on the button r text(like hypherlink in HTML)".Can u send me the simple example regarding this problem. I wrote some code but it is not working .Here i'm sending my code can u see and correct the code. This is my code :-- <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml"> <mx:Script> import flash.external.*; public function openWindow():void { var strFunction:String = "openWindow"; var strURL:String = "http://www.cflex.net"; var strCall:String = ExternalInterface.call(strFunction,strURL); } </mx:Script> <mx:Button label="Open Browser Window" click="openWindow()"/> </mx:Application> Thanks & Regards edeewan |
| Sponsored Links |
|
|||
|
This code shows how to open a link either in a new window or in the same
window. There are other options, see FB3 help. <?xml version="1.0" encoding="utf-8"?> <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml"> <mx:Script> <![CDATA[ public function openWindow(mode:String):void { var strURL:String = "http://www.cflex.net"; if(mode == "new"){ navigateToURL(new URLRequest(strURL), "_blank"); }else{ navigateToURL(new URLRequest(strURL), "_self"); } } ]]> </mx:Script> <mx:LinkButton label="Go to CFLEX in New Window (_blank)" click="openWindow('new')"/> <mx:LinkButton label="Go to CFLEX in this Window (_self)" click="openWindow('this')"/> </mx:Application> |
|
|||
|
Hey Greg ,that code (What u have sent) is working fine for "_self,_top,_parent"
but it is not working for "_blank".In my system it is showing error like this "Change pop-pop blocking settings for this website" in right down corner like small icon.Here am using Mozilla Firfox.What i have to do tel me Greg. Thanks & Regards, edeewan. |
![]() |
| Thread Tools | |
| Display Modes | |
|
|
- Contact Us
-|-
Adobe Dreamweaver Forums -|-
Archive -|-
Top -|-Rules/Disclaimer-|-Help/Support-|-Advertise