Array

Open in Browser

Must Read

Are Free Insurance Quotes Really “Free?”

It's a sad but true fact that we as a society have learned that we get what we pay...

Home Equity Line of Credit Vs Credit Card Rates

Despite major unease among literally billions of consumers worldwide due to markets across the globe becoming more unstable, it...

Choosing an Income-Based Repayment Plan For Direct Loan Consolidation

Direct loan consolidation is an excellent option that allows borrowers to consolidate their existing student loans. This is especially...

Strategies for Finding Appropriate Link Sites

Ideally, you should be linked from every high-traffic site that is of interest to your target market. Develop a...

Canon 7D Lenses and Focal Lengths

If you ask most photographers what they believe to be their most critical piece of photographic equipment, they would...

What Are Cheap Debt Consolidation Loans?

Cheap debt consolidation loans are loans that save the borrower money. This allows the borrower to pay off their...
Admin
test

From within your application, you can open a link using the device’s native browser in the same manner as you would in a traditional browser-based Flex application. This is accomplished with the URLRequest class. Simply creating a new URLRequest and passing it into the navigateToURL method will invoke the user’s browser to handle the request. Figure 6-1 shows the sample application running and Figure 6-2 shows the results of clicking on the Open button:

<?xml version=”1.0″ encoding=”utf-8″?>
<s:Application xmlns:fx=”http://ns.adobe.com/mxml/2009″
xmlns:s=”library://ns.adobe.com/flex/spark”>
<fx:Script>
<![CDATA[
protectedfunction sendIt_clickHandler(event:MouseEvent):void
{
var s:String = “”;
s+= address.text;
navigateToURL(new URLRequest(s));
}
]]>
</fx:Script>
<fx:Declarations>
<!– Place non-visual elements (e.g., services, value objects) here –>
</fx:Declarations>
<s:Label text=”URL” top=”40″ left=”50″/>
<s:TextInput id=”address” top=”30″ left=”160″ text=”http://www.happytoad.com”
width=”250″/>
<s:Button id=”sendIt” label=”Open” click=”sendIt_clickHandler(event)” top=”110″
left=”160″/>
</s:Application>

Open a link in a browser

Clicking the link launches the browser selector

LEAVE A REPLY

Please enter your comment!
Please enter your name here

Latest News

Digital Marketing for Beginners

Digital marketing for starter, Let to basic learning about connecting with your audience in the right place...

What are 7 things poor people do that the rich don’t?

1. poor people watch TV in which people read books how many hours you spend in front of the TV and when...

Top 18 best small business ideas for beginners starting

A small business can be frightening and requires plenty of careful planning there are many small business ideas which can be beneficial...

Summer that makes you happy

We saw were already here I've been thinking about some of the things. I used to do with my husband even though...

4 Point to helpful tips specifically for caregivers

What you need to take a vacation. I know it sounds impossible creative and try to make it work for you almost...

More Articles Like This