473,396 Members | 1,689 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Problem in loading PDF in Flex 4.5.

Hi All,
I'm trying to load PDF in flex 4.5. But facing some issues. Say the pdf is not resizing for its parent. I am attaching the screen shot of it. Also the code for loading is here.

Expand|Select|Wrap|Line Numbers
  1. <s:Group horizontalCenter="0"
  2.  
  3.          xmlns:fx="http://ns.adobe.com/mxml/2009"
  4.          xmlns:s="library://ns.adobe.com/flex/spark"
  5.          xmlns:mx="library://ns.adobe.com/flex/mx">
  6.  
  7.  
  8.     <fx:Script>
  9.         <![CDATA[
  10.             import flash.html.HTMLLoader;
  11.  
  12.             import mx.core.UIComponent;
  13.  
  14.             private var _html:HTMLLoader = null;
  15.             private var _wrapper:UIComponent = null
  16.  
  17.             public function loadContent():void
  18.             {
  19.                 var filePath:String = "table.pdf";
  20.                 if(!_html)
  21.                 {
  22.                     _html = new HTMLLoader();
  23.                     _html.height    = this.height;
  24.                     _html.width        = this.width;
  25.  
  26.                     _wrapper                = new UIComponent();
  27.                     _wrapper.percentHeight    = 100;
  28.                     _wrapper.percentWidth    = 100;
  29.                     _wrapper.addChild(_html);
  30.  
  31.                     this.addElement(_wrapper);
  32.                 }
  33.  
  34.                 _html.load(new URLRequest(filePath));
  35.             }
  36.  
  37.         ]]>
  38.     </fx:Script>   
  39.  
  40. </s:Group>
  41.  

Please anybody help me in fixing this.
Attached Images
File Type: jpg ScreenShot.jpg (57.9 KB, 183 views)
Mar 14 '12 #1
0 1963

Sign in to post your reply or Sign up for a free account.

Similar topics

1
by: Michael | last post by:
Greetings, I have a DLL which I am loading using Systm.loadLibrary(). I have put the DLL in a directory that is include in the PATH environment variable but I still get Unsatisfied Link Error. ...
1
by: Umashankar | last post by:
Dear Gurus, I am using listview control in a asp page to populate some database results.In some machines (which is having only OS and no other softwares installed) this control is not loading....
1
by: Nomad | last post by:
I'm trying to load an XML document into the DOM using the ActiveXObject I've succeeded in doing this on one machine. Which shouldn't becaus I've checked for the ActiveXObject and it doesn't...
0
by: Tom Heathcote | last post by:
Apologies for posting a flex++ question rather than a C++ question, but there does not appear to be a flex++ newsgroup... I am trying to rebuild some old lexical scanner / analyzer code, which I...
1
by: Tom Vukovich | last post by:
I'm having a problem loading an xmldocument from the web. The xml i wish to bring into the application is generated from a request to an ASP page. The following code does not work. ...
2
by: NGM | last post by:
Hello All I have a unmanaged C++ DLL, which has been wrapped up with a manged C++ DLL. When i refer to this managed DLL in Windows form based applications it works out fine. But when i refer to...
5
by: Pete Marsh | last post by:
Wondering if anyone can recomend some sample code for dynamically loading the GD module. I have tried setting the extension dir in php.ini, and loading the GD module from there when apache is...
6
by: Shigun | last post by:
On a website I am working on I am trying to load another page into a div on the the page the user does his work from. What I have works correctly in FireFox, but not in IE. I've rummaged Google for...
0
by: ndedhia1 | last post by:
I am having trouble loading a property file and keep getting this error when running my shell script that loads and runs my jar files, etc: no property file loaded, using defaults......
1
ifedi
by: ifedi | last post by:
Hi guys, Kindly spare a moment to look at this page: http://gottkann.com Most of the page content is designed to be loaded by AJAX (mostly jQuery .post and .get) on clicking the menu links on top...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.