HTML from ActionScript BUG

Keeping track of user actions in HTML from ActionScript
Document-level event listeners can be assigned to the
JavasScriptObject as illustrated in the example below, which traces
each DOM element in the HTML to receive an onmouseup event.
var doc:JavaScriptObject = event.currentTarget.domWindow;
doc.onmouseup = function():void
trace(arguments[0].srcElement);
on first mouse click does not work. It's a BUG???

Hi Golev,
Try registering the Document-level event listeners on the
"complete" event of <mx:HTML>, like the following full
example. Based on your description, it seems those events (such as
doc.onmouseup) are registered on the "click" event instead. If
that's the case, the events won't get registered until the 1st
click and consequently won't get fired until the 2nd click.
quote:
<?xml version="1.0" encoding="utf-8"?>
<mx:WindowedApplication xmlns:mx="
http://www.adobe.com/2006/mxml"
layout="absolute">
<mx:Script>
<![CDATA[
public function onHtmlComplete(event:Event):void {
var doc : * = event.currentTarget.domWindow;
doc.onmouseup = function():void {
trace(arguments[0].srcElement);
]]>
</mx:Script>
<mx:HTML id="html" location="
http://www.google.com"
complete="onHtmlComplete(event);" />
</mx:WindowedApplication>
/Vincent

Similar Messages

  • [svn] 949: Bug: BLZ-96 - When sending a HttpService request from ActionScript with multiple headers with the same name , it causes a ClassCastException in the server

    Revision: 949
    Author: [email protected]
    Date: 2008-03-27 07:12:59 -0700 (Thu, 27 Mar 2008)
    Log Message:
    Bug: BLZ-96 - When sending a HttpService request from ActionScript with multiple headers with the same name, it causes a ClassCastException in the server
    QA: Yes - try again with legacy-collection true and false.
    Doc: No
    Checkintests: Pass
    Details: Another try in fixing this bug. When legacy-collection is false, Actionscript Array on the client becomes Java Array on the server and my fix yesterday assumed this case. However, when legacy-collection is true, Actionscript Array becomes Java ArrayList on the server. So added code to handle this case.
    Ticket Links:
    http://bugs.adobe.com/jira/browse/BLZ-96
    Modified Paths:
    blazeds/branches/3.0.x/modules/proxy/src/java/flex/messaging/services/http/proxy/RequestF ilter.java

    Hi all!
    Just to post the solution to this if anyone ever runs accross this thread...
    For some reason i had it bad the first time, don't have time right now to see why but here is what worked for me:
    HashMap primaryFile = new HashMap();
    primaryFile.put("fileContent", bFile);
    primaryFile.put("fileName", uploadedFile.getFilename());
    operationBinding.getParamsMap().put("primaryFile", primaryFile);
    HashMap customDocMetadata = new HashMap();
    HashMap [] properties = new HashMap[1];
    HashMap customMetadataPropertyRoom = new HashMap();
    customMetadataPropertyRoom.put("name", "xRoom");
    customMetadataPropertyRoom.put("value", "SOME ROOM");
    properties[0] = customMetadataPropertyRoom;
    customDocMetadata.put("property", properties);
    operationBinding.getParamsMap().put("CustomDocMetaData", customDocMetadata);
    Basically an unbounded wsdl type is an array of objects (HashMaps), makes sense, i thought i had it like this before, must have messed up somewhere...
    Good luck all!

  • [svn] 931: Bug: BLZ-96 - When sending a HttpService request from ActionScript with multiple headers with the same name , it causes a ClassCastException in the server

    Revision: 931
    Author: [email protected]
    Date: 2008-03-26 11:31:01 -0700 (Wed, 26 Mar 2008)
    Log Message:
    Bug: BLZ-96 - When sending a HttpService request from ActionScript with multiple headers with the same name, it causes a ClassCastException in the server
    QA: Yes - we need automated tests for this basic case.
    Doc: No
    Checkintests: Pass
    Details: RequestFilter was not handling multiple headers with the same name properly.
    Ticket Links:
    http://bugs.adobe.com/jira/browse/BLZ-96
    Modified Paths:
    blazeds/branches/3.0.x/modules/proxy/src/java/flex/messaging/services/http/proxy/RequestF ilter.java

    Hi all!
    Just to post the solution to this if anyone ever runs accross this thread...
    For some reason i had it bad the first time, don't have time right now to see why but here is what worked for me:
    HashMap primaryFile = new HashMap();
    primaryFile.put("fileContent", bFile);
    primaryFile.put("fileName", uploadedFile.getFilename());
    operationBinding.getParamsMap().put("primaryFile", primaryFile);
    HashMap customDocMetadata = new HashMap();
    HashMap [] properties = new HashMap[1];
    HashMap customMetadataPropertyRoom = new HashMap();
    customMetadataPropertyRoom.put("name", "xRoom");
    customMetadataPropertyRoom.put("value", "SOME ROOM");
    properties[0] = customMetadataPropertyRoom;
    customDocMetadata.put("property", properties);
    operationBinding.getParamsMap().put("CustomDocMetaData", customDocMetadata);
    Basically an unbounded wsdl type is an array of objects (HashMaps), makes sense, i thought i had it like this before, must have messed up somewhere...
    Good luck all!

  • Can I programmatically change the printer paper size from ActionScript?

    Hi,
    I'm a newbie Flash/ActionSript developer and I have been searching for answers for a while with no luck. I wonder if I can get some pointers from this forum.
    I'm trying to programmatically print a movie clip to 8.5" x 11" plain paper regardless of the current paper size setting in the printer. e.g if the user's printer is currently set to use paper size A4, can I change the setting to Letter (8.5" x 11") from ActionScript at runtime? I use PrintJob class for printing the movieclip.
    According to the ActionScript online API spec ( http://www.adobe.com/livedocs/flash/9.0/main/wwhelp/wwhimpl/common/html/wwhelp.htm?context =LiveDocs_Parts&file=00002066.html), I can only READ the paper size setting after the call to PrintJob.start. I can't believe that we are not allowed to change the setting. Maybe I missed something here. Can somebody help me out?
    Thanks in advance!

    check your duplicate thread.
    and, please don't cross-post.

  • Can I programmatically change printer paper size from ActionScript?

    Hi,
    I'm a newbie Flash/ActionSript developer and I have been searching for answers for a while with no luck. I wonder if I can get some pointers from this forum.
    I'm trying to programmatically print a movie clip to 8.5" x 11" plain paper regardless of the current paper size setting in the printer. e.g if the user's printer is currently set to use paper size A4, can I change the setting to Letter (8.5" x 11") from ActionScript at runtime? I use PrintJob class for printing the movieclip.
    According to the ActionScript online API spec ( http://www.adobe.com/livedocs/flash/9.0/main/wwhelp/wwhimpl/common/html/wwhelp.htm?context =LiveDocs_Parts&file=00002066.html), I can only READ the paper size setting after the call to PrintJob.start. I can't believe that we are not allowed to change the setting. Maybe I missed something here. Can somebody help me out?
    Thanks in advance!

    you can't change the paper size used in client side printer.

  • Nasty HTML / Outlook 2007 Bug in iPhone 2.0?

    Anyone else notice a nasty HTML / Outlook 2007 bug with iPhone 2.0? I've pasted the bug that I submitted to Apple below. So far I've gotten no response. =(
    Summary:
    I have found a major bug with sending and receiving HTML emails between iPhone 2.0 and Outlook 2007. When you reply to any email that comes from Outlook 2007 that reply will include broken HTML tags as part of the message. As a result, with each additional reply the message will double in size. It appears these additional replies hit the broken HTML tag and then insert another entire copy of the email. This happens with each and every reply, until after four or five when the phone can no longer deal with the message due to size.
    Steps to Reproduce:
    Send an email with HTML formatting to yourself using Outlook 2007.
    Reply to the message from the iPhone. The first reply will be fine.
    Reply using Outlook 2007 (make sure the formatting is still HTML).
    Reply to the message from the iPhone. This reply will include broken HTML tags, and begin the repeat copies inside the email.
    Expected Results:
    No formatting issues on replies, no repeat copies of the email inside each reply causing unusable message size growth.
    Actual Results:
    Broken HTML tags appear in the replies and cause the message to double in size with each reply. An example of some of the tags that show up are things like:
    color:#1F497D">
    or
    font-family:"Tahoma","sans-serif";font-weight:bold">
    They do not have the starting "<", which appears to be the root of the issue. These tags will show up near special HTML formatting, such as links or font changes.
    Regression:
    The problem always happens on iPhone 2.0 when an HTML formatted reply Outlook 2007 is part of the email chain. This appears to happen with all types of accounts.
    Notes:
    I'm assuming that with as many people that use Outlook 2007 I'm not the only person to report this. Our company uses Outlook 2007 as a standard deployment and this bug alone is making us unable to deploy iPhones to employees. I'm really hoping that a fix is already in the works and will be in the next update of 2.0!
    Thanks.

    eric9603,
    Have you been able to reproduce this with emails back and forth with any other Mail client besides Outlook that composes in HTML?
    Outlook 2007 does not use a browser based HTML generator or renderer. It uses Word's HTML engine for both generating and rendering HTML messages.
    Thank you,
    Nathan C.

  • How to fire TreeEvent from ActionScript?

    Hi,
    I want tp fire a TreeEvent (TreeEvent.ITEM_OPEN,TreeEvent.ITEM_CLOSE,etc.) from ActionScript.
    I want to be able to open branches, double-click node(leaf),etc from ActionScript.
    Can anybody provide an example or suggest  a way to accomplish this.
    Thanks,
    Pradeep.

    I'm not very familiar with the Automation framework, but I think you're getting your path's crossed.  You're TreeEvent should really only be tied to the tree you're working with and should be the handler for all items in the Tree.
    If you're simply trying to automate the tree opening for you...I would think that the Automation framework had some funtions to take an object and an event that should it do probably based on a timer value, but I'm not too familiar with Automation in Flex.  From here I can't really help you as I have never messed with the Automation Framework...
    I came across this in a quick google, so hopefully this helps:
    http://livedocs.adobe.com/flex/3/html/help.html?content=functest_components2_10.html

  • Resetting License from Actionscript 3

    Hi,
    Currently I have a video whose license has a playback window set:
    http://help.adobe.com/en_US/flashaccess/2.0/javadocs/com/adobe/flashaccess/sdk/rights/Play Right.html#setPlaybackWindow(long)
    Now when the player gets this license and initiates playback, then the license expiration starts then.  What I want to be able to do is within the player, I want to be able to reset that license, so that I can download a new license and restart the playback window countdown again.
    Is this possible?  I tried looking at DRMManager (http://help.adobe.com/en_US/FlashPlatform/reference/actionscript/3/flash/net/drm/DRMManage r.html), but it doesn't have anything pertaining to resetting/clearing out the license from Actionscript.  The two ways I know how to clear out my license is to do it manually by:
    1) http://www.macromedia.com/support/documentation/en/flashplayer/help/settings_manager08.htm l
    or
    2) By clearing out the license files/directories.
    I would like to be able to clear out a specific license from within the Actionscript 3 environment.
    Any help would be greatly appreciated.  Thanks!

    Hi Eric,
    Thanks for the feedback.  Is there a way to specifically set the license expiration date relative to the playback time, so the playback window and the license expiration time are the same?
    According to the docs http://help.adobe.com/en_US/flashaccess/2.0/javadocs/index.html?com/adobe/flashaccess/sdk/ license/License.html , there's no way to set relative license end date, so it seems very impractical to somehow set it to the same time as when the playback window ends.
    To give you some context on what I'm trying to achieve, I'm trying to make it so that a viewer of the media content periodically grabs a new license to watch the content (let's say 24 hours).  This is so that the license server can say at any moment the user cannot grab a new license (let's say we do that 60 days after the content was initially released).  Ideally we would only have to run the media content through the flash packager only once with the proper license variables  (and obtain an encrypted media file and voucher) so that the player can only use a license for 24 hours and continually request updated licenses as they expire.  Is this possible to do this?

  • "Rough" GIF export from ActionScript 3 files impossible?

    Hello,
    I just upgraded from Flash CS3 to Flash CS5, and I've been playing with the various new features. However, I've just encountered an odd problem that I can't seem to find a solution to.
    In the past, I've made animated GIFs in CS3 by exporting them with the "Smooth" box unchecked. This was really convenient for me because not only could I export crisp pixel bitmaps from Flash, but I could edit it in another program later. I was planning on making some GIF animations via this process with the aid of the bone tool in CS4 and 5.
    When I tried exporting frames of of a figure created with the bone tool in CS5, however, I got images that were fuzzy and often had distorted colors. After some time, I realized that this was because in CS3, I had exported the images from ActionScript 2 files, while the bone tool only works in ActionScript 3 files.
    Is it not possible to export "rough" GIFs from ActionScript 3 files, or is there a trick to doing that that I'm somehow missing?

    I'm sorry for not making it clear in my initial post, but it doesn't matter whether I create an image using the bone tool or not -- any GIF image exported from an AS3 file always has an antialiased appearance, even when the Smooth box is unchecked.
    To show you what I mean, here's a simple GIF image I exported from an AS2 file:
    Notice that all of the lines are simple and pixellated, with no antialiasing at all. This is the kind of GIF I want to export from an AS3 file.
    Now here's the exact same image I exported from an AS3 file, with the exact same export settings:
    As you can see, all of the lines look smoothed, even though I made sure the Smooth box was unchecked.
    Is there anything I can do to correct this problem?

  • Remove HTML from Interactive report download

    I have interactive reports where the column link on a specific column has to be dynamic, that means, it cannot be hard coded in the column link attributes. The following is an example of one such report query:
    case when d.object_type_description ='Business Service' then
    '< href="f?p='||:app_id||':183:'||:app_session||'::::P183_OBJECT_ID:'||d.id||'">'||d.object_name||'</>'
    when d.object_type_description = 'Real Time Event' then
    '< href="f?p='||:app_id||':162:'||:app_session||'::::P162_OBJECT_ID:'||d.id||'">'||d.object_name||'</>'
    else
       null
    end as "OBJECT NAME"As you see in the above example, the link on the "Object Name" column could either redirect to page 183 or to page 162 based on the "Object Type Description" column.
    The column attribute of the "Object Name" column has "Display Type" set to "Standard Report Column". That works perfectly fine in the UI of the report. However, if I download the IR data (in any format) from the Actions -> Download menu, the object name column values are downloaded with the HTML characters as:
    < href="f?p=15548:183:6072319179284::::P183_OBJECT_ID:255245470513999672860510787772603748464">JP010000</>where JP010000 is the object name.
    Is there a way I can strip the HTML from the column values in the downloaded files?
    I am using Apex 4.1.

    Rohit,
    You can define the link in the query, make it hidden, use the value as column link URL. So, your query will look like the following:
    d.object_name,
    case when d.object_type_description ='Business Service' then
        'f?p='||:app_id||':183:'||:app_session||'::::P183_OBJECT_ID:'||d.id
    when d.object_type_description = 'Real Time Event' then
        'f?p='||:app_id||':162:'||:app_session||'::::P162_OBJECT_ID:'||d.id
    else
       null
    end linkChange the display type of LINK column to Hidden. In column link, enter #OBJECT_NAME# as Link Text. Select URL as Target. Enter #LINK# as URL value. In APEX 4.2, you can do this in easier way by defining HTML Column Expression.
    Regards,
    Christina
    Edited by: cbcho on Sep 27, 2012 11:35 AM

  • Can I import HTMLs from inside the project and use as portlet page ?

    As you know, I am using Java Studio Creator 2 Update 1 for my current portal project. I have created JSR-168 JSF Portlet Project for my portlet development.
    As I have some html pages ready for my development,
    Can I import HTMLs from inside the project and use as portlet page for my project?
    I did the followings steps:
    1: In side the project - File -> Add Existing Item -> Web Page ( imported test.html page from my local folder)
    2: Let it convert some of the tags for me ( so now it becomes - �test.jsp� )
    3: Set it to initial view.
    4. A default portlet page � newPortletPage.jsp is still there with no initial view.
    Now after doing this, No Visual Designer and Properties window available to for that �test.jsp� page. Though it allowed me to �build� the project successfully.
    When I build and run the portlet application, got the error message �Error occurred in portlet!� on Pluto Portal. Please advice.

    You do not open fcpproject files. You don't double click or anything else. The files have to be in the correct folder structure in the Final Cut Projects folder and the application opens them automatically. Can you post screen shots of the Final Cut Projects folder and its location.

  • 0 down vote favorite share [fb] share [tw]        How to hide cut/copy/paste/Replace- menu on the UIWebView when it is being displayed over the keyboard.  Detail: I am having a HTML from, having text box, displayed using UIWebView. If user types in text b

    How to hide cut/copy/paste/Replace… menu on the UIWebView when it is being displayed over the keyboard.
    Detail: I am having a HTML from, having text box, displayed using UIWebView. If user types in text box it shows the keyboard. Now If user tap and hold on text box it shows a popup menu. Now while keyboard and pop up are being displayed user scrolls the view. At this time it shows pop up over the keyboard which I need to hide.
    I tried setMenuVisible of UIMenuController when popup rect and keyboard rect intersects each other on viewDidScroll but it didn't help me.
    Any clues will help a lot.
    Thanks.

    You are more likely to get an answer if you post programming problems to the Developer forum. This forum is intended for normal user level problems.

  • Is there a way to prevent HTML from being displayed in forum?

    Is there a way to prevent HTML from being displayed in forum in BC to avoid linking to other sites on an eCommerce site?

    Thank you for your post!
    Unfortunately there isn't a way to restrict customers to post on your forums links to other sites.
    However what I suggest here is to choose to moderate each forum post and this way you can choose to approve or remove links from the posts sent by customers.
    I hope this helps!
    Andrei

  • Embedding html from youtube no longer works

    embedding html from youtube no longer works??

    You need to select the 'Enhanced Privacy' check box in YouTube before getting your embed code.

  • What line(s) of javascript is used to disable/enable html from being written for .mucows

    The question kinda says it all but some widget developers use javascript to disable html from being written. I'm wondering how it's done

    You can have different <pageItemHTML> sections based on the value of an option. You could have one that's empty and one that's not.
    Download all the samples from the documentation page:
    MuCow Documentation
    There's a sample named 'Fox.mucow' which uses different HTML based on the value of an option.

Maybe you are looking for

  • No multi-channel audio from DVD Player or Quicktime?

    I have the A52Codec 1.7.6 installed. The codec preferences are set to output multi-channel audio. I have my Audio MIDI setup speaker configuration setup for multi-channel audio and the speaker assignment tests are all perfect. VLC plays back files wi

  • Safari not opening... please assist.

    Alright, Safari won't open on my phone or ipad, it simply freezes (page blank) and eventually closes. I tried going to general settings to reset the cookies, however once I hit 'Safari' in the settings it freezes. However, before I do that if I click

  • VCA sign fails continually. Now won't go online

    For the past few weeks have been receiving sporadic (multiple) VCA sign on failure messages during the day, I'm not attempting to sign on, I just receive the pop up. Last night received 89 of them!!! VCA says it's offline.  I've tried loging in it sa

  • Trying to import imovie 9 proj into imovie 11 and its not recognizing it

    Can anyone offer information on this issue please?

  • My Nokia n97 mini was stolen, and when i found it ...

    I have a problem, my Nokia n97 mini was stolen, and when i found it my "lock code" was chandged. . .i used "hard reset" bud my phone dosent work at code 12345 or 0000. . .how can I ever found out witch is the code after "hard reset" ? O.o Moderator's