Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7173361
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T15:48:30+00:00 2026-05-28T15:48:30+00:00

I am running Flex mobile project and I would like my mobile app to

  • 0

I am running Flex mobile project and I would like my mobile app to be able to load and display pdf files that are saved locally. I do not want to go out to the web to access these pdf files.

I cant figure out how to make this code work for a locally saved file.

Error MSG: “Error #2044: Unhandled ErrorEvent:. text=Load error.”

Does anyone have a suggestion?
Thanks!

<?xml version="1.0" encoding="utf-8"?>
<s:View xmlns:fx="http://ns.adobe.com/mxml/2009"
    xmlns:s="library://ns.adobe.com/flex/spark"
    overlayControls="true" title="PDF Display"
    viewActivate="view1_viewActivateHandler(event)"
    viewDeactivate="removeStageWebViewHandler(event)">

<fx:Script>
    <![CDATA[
        import mx.events.FlexEvent;
        import spark.events.ViewNavigatorEvent;

        private var myWebView:StageWebView;

        protected function view1_viewActivateHandler(event:ViewNavigatorEvent):void {
            myWebView = new StageWebView();
            myWebView.viewPort = new Rectangle(5,60,stage.stageWidth-10,stage.stageHeight-140);
            myWebView.stage = this.stage;
            myWebView.loadURL( "assets/sample.pdf");
        }

        override protected function updateDisplayList(unscaledWidth:Number, unscaledHeight:Number):void {
            if (myWebView) {
                var point:Point = localToGlobal(new Point());
                myWebView.viewPort = new Rectangle(5,60,stage.stageWidth-10,stage.stageHeight-140);
            }
        }  

        protected function goBackHandler(event:MouseEvent):void {   
            navigator.popToFirstView();
        }

        protected function removeStageWebViewHandler(event:ViewNavigatorEvent):void {
            myWebView.stage = null;
            // just remove the target and will leave.
        }

    ]]>
</fx:Script>

<s:actionContent>
    <s:Button label="BACK" click="goBackHandler(event)"/>
</s:actionContent>
<s:Image x="-1" y="2" source="assets/eventsback.jpg"/>

</s:View>
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-28T15:48:31+00:00Added an answer on May 28, 2026 at 3:48 pm

    The Android Issue is actually a fundamental Android Browsers OS Issue. Think of the AIR StageWebView as a Hole carved out of your app showing you the browser and all its capabilities.

    If your OS supports viewing PDFs, then your App’s StageWebView will also. on Android 1.0 – 3.0 when you try and view a PDF it will download the doc it and Hand Shake it off onto another application like Acrobat.

    leaving to do something like:
    http://forums.adobe.com/thread/864113

    Hopfully this will be fixed in the newest version of Android…4.0

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm running my first project that I'm compiling with flex builder. Before I used
I have a flex app that has several timers running for various amounts of
I have BlazeDS running in an instance of Coldfusion 8. A flex chat app
I've got a Flex App running at 100% width and 100% height. The embed
I have a large flex application (the app) running on one server, and many
I'm trying to reuse the HTTPService object in a flex app but I'm running
I have a AIR for mobile pure AS3 project that saves a file on
I have a flex application that communicates via BlazeDS with two webapps running inside
I'm trying to develop a Flex Mobile / PHP application, and I'm running into
I'm using the MVC model in my flex project. What I'd like is to

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.