Open url request from PopUpManager

Hi,
I have a function which opens a new browser window with the result of a URL request (an image). I wonder if  I can do the same but with a window "embedded" in the flash application.
I saw there is a class called PopUpManager. I understood that I have to create a new component ("popup") with the data for the new window. The problem is that I don't know how to pass the result of the URL request to that popup component.
Is it possible at all? Is there any other alternative?
Regards,
Manolo

Hi there
Yep cool with the PopUpManager.centrePopUp.
As for saving an image.  You can save graphics from Flex by specifiying a rectangular region you want to save.  You can save the selected region out as a jpg or a png using the encoders.  In the example below I have saved out an image. 
<?xml version="1.0" encoding="utf-8"?>
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute">
<mx:Script>
<![CDATA[
     import mx.graphics.codec.JPEGEncoder;
     import flash.utils.ByteArray;
     private function saveImage():void {
          var bitmapData:BitmapData = new BitmapData(myImage.contentWidth, myImage.contentHeight);
          bitmapData.draw(myImage);    
          var jpeg:JPEGEncoder = new JPEGEncoder();
          var byteArray:ByteArray = jpeg.encode(bitmapData);
          var file:FileReference = new FileReference();
          file.save(byteArray,'TestImage.jpg');
]]>
</mx:Script>
<mx:Image id="myImage" x="78" y="33" width="283" height="180" source="http://www.maniacworld.com/amazing-cars.jpg"/>
<mx:Button x="78" y="236" label="Button" click="saveImage()"/>
</mx:Application>
Note you need to be compiling for Flash PLayer 10 in your Flex compiler settings as that allow you to read and write local files.
Hope it helps
Andrew.

Similar Messages

  • Unable to open URL attachment from SBWP in CRM WEB UI

    Hello Gurus,
    Need your help please. I'm having some problem opening the URL attachment from SBWP via CRM 7 WEB UI (I used a Transaction Launcher for SBWP). The attachment is a Webdynpro application.  I am able to open the attachment in SAP GUI, but not in CRM WEBUI. This problem occured when we update the SP level of CRM 7.
    Here's the scenario,
    - whenever I click the attachment, it open a new window, which also happen even before SP level update, with the following information:
      Execute an Application on FrontEnd
      Please wait. You will be forwarded automatically.
      This page is included for technical reason.
      Execute program.
      Status: Displaying Office Document ..........
      After a couple of seconds, it will return to the Workflow Workplace screen.
    I have checked the workflow log and found no inconsistency on the attached URL.
    Immediate response would be highly appreciated. Thanks in advance.
    Regards,
    Edwin

    Thanks for the reply WD ABAP.
    Yes, I did try to use the functionality of Worklist and the URL attachment successfully opened. However, there are some limitation in its functionality as indicated in the link below that opted us to use the SBWP in CRM WEB UI via transaction launcher.
    http://wiki.sdn.sap.com/wiki/display/CRM/CRMWorklist-AdvancewithDialognotSupported
    We don't want to adjust the logic of our existing workflow at this point as described in the above link as it will entails end-to-end testing again. We just encountered this issue when we update the SP level of CRM 7.
    Hope there is an alternative solution without shifting us to Worklist.
    Regards,
    Edwin

  • Internet explorer unable to open url shortcuts from networked locations

    Hi Everyone
    I have an issue with Internet Explorer not opening up URL shortcuts from networked locations.
    The setup I have is a Windows 2008R2 Terminal Server (patched and up to date), which uses setup for folder re-direction (all folders bar app data) to redirect the data to a network share on the same server (ie, the my documents folder is redirected to \\server\users\username\my
    documents).
    When the user opens internet explorer and tries to open a favorite, the active tab sits there with a connecting... displayed on it, and does nothing else. Opening the URL shortcut directly from the favorites folder does the exact same thing.
    However, when I login as the domain administrator account, and do the same thing, it works as it should.
    There are two ways that I have found to get it working is to not redirect the favorites folder, and disabling the "Enable Protected Mode" for the Internet zone (Internet Options > Security Tab > Select Internet Zone, and uncheck the protected
    mode box).
    I have tried setting the network shares to be located within the local intranet zone, and I do believe that it is setting correctly since I can open an html document in the share and it shows the intranet zone in the status bar.
    Does anyone know of a way of getting the favorites working when they are stored on a network share as a re-directed folder?
    Many thanks,
    Sam.

    Hi,
    Based on my test, "Enable Protected Mode" for the Internet Zone shouldn’t cause this problem. I try to move a test user’s Favorites folder to a shared folder and then try to open the Favorites shortcuts from IE, they work fine.
    Could open \\server\users\username\my documents folder and directly open the shortcuts by double-click them?
    If not, let’s use Process Monitor to trace the process:
    Process Monitor
    http://technet.microsoft.com/en-us/sysinternals/bb896645.aspx   
    Download and run it. Click File menu, check Capture Events, double-click the shortcuts in shared folder, wait for some time, when the error occurs, uncheck Capture Events again. Exported events to Logfile.PML and upload the file to Windows Live SkyDrive
    (http://www.skydrive.live.com/). If you would like other community member to analyze the report, you can paste the link here, if not, you can send the link to
    [email protected] (with this thread title or link in the email. Please don’t share documents with this address).
    Thanks.
    This posting is provided "AS IS" with no warranties, and confers no rights. Please remember to click "Mark as Answer" on the post that helps you, and to click "Unmark as Answer" if a marked post does not actually answer your
    question. This can be beneficial to other community members reading the thread.

  • Make Firefox open URLs passed from external applications in new tabs

    I upgraded Firefox (Mac) from 3.6.13 to 3.6.14 yesterday.
    Since then Firefox does not respond to URLs passed from external applications, as it has always done.
    The external apps pass the URL, FireFox is brought to the front, but no Tab (or new window) is opened.
    Nothing else has changed. Firefox is selected as my default browser (in Safari Prefs) and there is only one copy of FireFox on my laptop,

    Hi David
    Go to Safari Preferences>General. At the bottom you'll see an option for opening in a tab. Makes sure Tabs are enabled in your Tab panel.

  • Mac firefox cannot open .url files from PC

    I have hundreds of pc .url files that I want to import as bookmarks.
    Mac Firefox opens the files as a text file, not as a web page.
    Mac Safari can open them no problem.

    If you have still access to the computer with the .url files then export them via IE to an HTML file.<br />
    If you can open them in Safari then bookmark them and export them in Safari to an HTML file.<br />
    Then you can import that HTML file in Firefox.
    [[Importing bookmarks and other data from other browsers]]
    http://kb.mozillazine.org/Backing_up_and_restoring_bookmarks_-_Firefox

  • Firefox won't open url links from mail

    I don't know if this question has been asked yet, but I am having problems opening links from mail. I am using Firefox 3.5.3 and Snow Leopard. Every time I click on a link in my mail firefox opens to the homepage. Firefox will only link to the proper webpage if it is already opened. Does anyone know if there is a way to link directly to the webpage when firefox is not opened?
    Thanks

    Same thing here. Although mine just doesn't do anything. Firefox is open, but no new tab is created at all. Clicking a link in Mail does seem to activate Firefox's menu, though.
    I just switched to using Firefox a few days ago, because my Safari kept crashing. Since my work is entirely on the web, I had to switch to keep functioning (but that's another issue).

  • How to open url request in the same window

    hail unto theeeee..
    I finally got my buttons to work, but now I need help getting
    them to open in the same window. As of now each button opens a
    separate new window. UGGGGG!
    Thanks in advance!

    Thank you thats what I needed alright! problem solved.

  • Open URL Website from WHEN BUTTON PRESSED

    I need to open an internal website when a button is pressed on Forms 9i, which is the best and simplist way to go about it, using the available inbuilt forms 9i functions.
    Any ideas?????

    Hello,
    Use the Web.Show_Document() built-in.
    Francois

  • Unable to open url from email

    suddenly today i am unable to open url link from my eudora mail program. firefox is my default browser. never had this problem before.

    This could be a Launch Services issue. The following article describes how to manually reset Launch Services — the notes at the bottom of the article also provide information about the side effects of deleting each of the files involved:
    Resetting Launch Services
    If you prefer using a cache cleaning utility instead of following the manual procedure described in the previous article, take a look at this other article for general troubleshooting and cache-cleaning procedures. Actually, you should also verify/repair the startup disk (not just permissions), as described there:
    Resolving Disk, Permission, and Cache Corruption
    The most appropriate utility for this particular problem probably is Tiger Cache Cleaner, but you may also want to consider other utilities, such as OnyX, or Cache Out X, which are free. Whatever utility you choose, be sure to read this first:
    Side effects of System cache cleaning
    As an example, this is how you should proceed with OnyX:
    1. Quit all applications.
    2. Launch OnyX and enter your administrator password.
    3. Go to Maintenance > Reset and check LaunchServices database.
    4. Un-check any other pre-checked options.
    5. Click the Execute button.
    6. Restart the computer.
    BTW, if you’re running Mac OS X 10.4 (Tiger), as your profile indicates, it would have been more appropriate to discuss this in the Mail & Address Book - Tiger forum. If the discussion applies to both Mail 1.x and Mail 2.x, it doesn’t really matter, but it’s difficult to know that in advance.

  • Open url from xchat in opera

    I'd like to open urls from xchat in opera.
    Under settings>advanced>url handler:
    !opera -remote 'openURL(%s)'
    xchat has tcl as an optional dep, so I installed that.
    This is in xfce4 and I have set opera as the preferred browser.

    Well, I'm afraid that is not an option.
    The goButton is in a table row. There are lots of rows so if I use EL for Destination attribute the URL would be retrieved for each of rows.
    The method of URL retreiving is heavyweight operation which includes calling plsql functions, working with strings and others. So if I do it for each table row my application hungs and then I receive an exception of CPU usage.
    That's why I switched to normal commandButton witch actionListener which retrieves url on click - only once. So I need to open URL from Java.

  • Open URL from Java in a new browser tab

    Hi OTN,
    Surprisingly can't find the implimintation.
    In an ADF managed bean I retrieve String url. I need to open a new browser tab with this url.
    Found this thread Open a url in a new window in the backing bean which shows using javascript "service.addScript(facesContext, "window.open(http://www.google.coml)");".
    But in my case in doesn't work. The code is executed, but nothing happens. Maybe because the bean is called from a taskflow inline popup.
    ADF 11.1.1.4
    Thanks.

    Well, I'm afraid that is not an option.
    The goButton is in a table row. There are lots of rows so if I use EL for Destination attribute the URL would be retrieved for each of rows.
    The method of URL retreiving is heavyweight operation which includes calling plsql functions, working with strings and others. So if I do it for each table row my application hungs and then I receive an exception of CPU usage.
    That's why I switched to normal commandButton witch actionListener which retrieves url on click - only once. So I need to open URL from Java.

  • Captivate 4 Open url from a button not working?

    Hi All,
    I have published a scorm course from captivate 4 and have installed to our servers. I would like to have a link to a document that is online (.doc) but whenever I click the transparent button it starts to load, opens a window (which has the correct title name) but then disappears with no warning or error message.
    The link resides behind a transparent button, and has the settings On Success open url or file in a new window.  I know the problem is not specific to this document because I have had the same problem with a completly different online file location in the past.
    Please Help!!
    Many thanks in advance.
    Chris Maile

    Hi there
    Please send me a private E-Mail message to rstone75 (at) kc (dot) rr (dot) com and advise of the exact file name of the file you are linking to.
    I'll send you back a file that you can use to test and see if the link works.
    Cheers... Rick
    Helpful and Handy Links
    Captivate Wish Form/Bug Reporting Form
    Adobe Certified Captivate Training
    SorcerStone Blog
    Captivate eBooks

  • PROBLEM while using URL in order to open a file from a servlet

    Hi,
    I am having a problem while trying to open a file from my servlet by using URL connection. Following is my code sample. what happens is when I first run my project it opens the file but after that when I rerun it again and again it sometimes opens it and sometimes not. if it can't open it it gives an error saying "the file is damaged and couldn't be repaired". I don't get any exceptions. if you guys can help me I will appreciate it so much... thanks.
    here is my code :
    URL url = new URL("http://demobcs.ibm.com:81/test.pdf");
    resp.setContentType(getContentType("http://demobcs.ibm.com:81/test.pdf"));
              ServletOutputStream sos = null;
              BufferedInputStream bis = null;
              try {
                   sos = resp.getOutputStream();
              } catch (Exception e) {
                   System.out.println("exception !!!!");
                   e.printStackTrace();
              System.out.println("burada2");
              try {
                   byte[] bytes = new byte[4096];
                   //bis = new BufferedInputStream(conn.getInputStream());
                   DataInputStream in = new DataInputStream(url.openStream());
                   //DataInputStream in = new DataInputStream(conn.getInputStream());
                   bis = new BufferedInputStream(in);
                   int j;
                   while ((j = bis.read(bytes, 0, 4096)) != -1) {
                        try {
                             sos.write(bytes, 0, 4096);
                             System.out.println("file is being read ...:");
                        } catch (Exception e) {
                             e.printStackTrace();
                   in.close();
                   bis.close();          
                   //sos.close();
              } catch (Exception e) {
                   System.out.println("exception :"+e.toString());
                   e.printStackTrace();
              }

    You are writing (<filesize> mod 4096) bytes of crap at the end of the file. Use your variable j instead for the number of bytes to write in your loop.

  • Open URL in new window from page process

    I have a Page process that returns a URL (stored in 'l_val' field). Within this process, what is the best way to open that URL (stored in l_val) in a new window?
    thanks
    DECLARE l_clob clob;
    l_xml xmltype;
    l_val clob;
    BEGIN
    for c1 in (select clob001
    from apex_collections
    where collection_name = 'CENTRIS_IEP_VIEWER') loop
    l_clob := c1.clob001;
    exit;
    end loop;
    l_xml := xmltype.createxml(l_clob);
    l_val := dbms_xmlgen.convert(
    l_xml.extract(
    '//GetIEPUrlWithAuditResult/text()'
    , 'xmlns="http://www.iepdirect.com/CentrisWebServices/IEPViwer"'
    ).getstringval()
    , 1
    END;

    Hello,
    You can create a application process using this code and call that process from a javascript function and return that URL to the javascript function there you can open a popup easily.
    If you want you can open a popup from process, you can do that using htp.p() function, I had tried this once but what it does was, it opens a popup but it clears out my parent page, I was not be able to see anything on my parent page.
    Thanks
    Tauceef

  • Unable to delete a request from a Cube which is loaded by Open hub to flat

    Hi,
    We have one Cube from which we are transferring data to a flat file by open hub.
    the DTP for the OPEN HUB is delta DTP.
    Now when i am trying to delete a request from Cube its not allowing me.
    Its giving error as request is already updated to the target so delete the request from target first.
    I tried deleting the open hub request entry from RSBKREQUEST table.
    but still its not deleting the request from the Cube.
    Can you please help me in solving this problem.
    Thanks in Advance,

    I think request is having datamart, which is not allowing it to delete.
    You can try to reset (delete)  the datamart by clicking on it in cube request and then try to delete.
    Or if it does not work, you can delete it from RSICCONT table, which will delete the request from cube also.

Maybe you are looking for

  • Is there a way to detect the end of a video?

    Is there a way to detect the end of a video.. .mp4 or youtube? I want to be able to detect the end of a video and then have it do something...ie play on timeline or go to and play symbol.

  • Java.lang.NoClassDefFoundError while calling a java class from BPEL

    Hi, I'm calling a java class to convert JSON to XML using BPEL. I have imported all the necessary jar files in the project and compiling done successfully. But at runtime , i get the java.lang.NoClassDefFoundError: net/sf/json/JSON error. For this i

  • [Solved]conky-lua

    I was trying to install conky-lua when I got this error, and I don't know how to proceed from here. Please help. Last edited by Laplace_ (2009-12-29 05:15:15)

  • Font Changing in report

    hi all i want to change font in drill down or interactive report how can i change is it any function available ? help me

  • I Replaced my Artfile.bin and now my buttons are all messed up.

    Can sombody just drop a mediafire link or somthing? i don't know what i did wrong, i replaced my Sartfile.bin and my Artfile.bin. Can sombody send me one? Also my buttons look like this: