IE/ExternalInterface doesn't return any value if added with appendChild film

There is a problem with IE/ExternalInterface if the movie is added to the DOM appendChild f.ex. JavaScript functions are called, but they do not return any value.

First response was this is 3rd part/Adobe issue.

This fixation with innerHTML is not the solution. Here, using suggestions?

Simplified test cases has

" flashMovie var = ' < OBJECT id ="testId"codeBase ="http://fpdownload.

/ / Works in IE and FF

document.getElementById("testdiv").innerHTML = flashMovie.

/ / ExternalInterface.call("saveglobalscore",score) call JS but does not return a value in Internet Explorer. Works in FF

var tempDiv = document.createElement("div");   

tempDiv.innerHTML = flashMovie.

document.body.appendChild (tempDiv);

Here's the complete code

http://pastebin.com/fbc0aa9a

Here's the AS3 code for ajax.swf

http://pastebin.com/d4efd47b

H

That did the trick - the sequence of adding objects in html format (works in both browsers for me):

var tempDiv = document.createElement ("div");

first add div DOM

document.body.appendChild (tempDiv);

then adds html div

s = tempDiv.innerHTML;

In addition, your swf get error when they are not incorporated. You should always check it ExternalInterface is available:

{if (ExteralInterface.available)}

No matter what

}

Tags: Adobe Animate

Similar Questions

  • Dialog API doesn't return a value on DevAlpha

    Hi, Im implementation of customAskAsync with the D_YES_NO button. I'm warning index in dialogCallBack (index) or not click on the dialog box. When I test with ripple on Chrome, I get the correct values. When I package and test on DevAlpha, I don't get all the values returned. In the alert, all I get is [object Object], which is returned? I simplified the code below.

    function confirmationDialogPurge(message, dialogTitle) {
        try {
            blackberry.ui.dialog.standardAskAsync(message,
                blackberry.ui.dialog.D_YES_NO, confirmationPurgeTable, {
                title : dialogTitle,
                size : blackberry.ui.dialog.SIZE_LARGE,
                position : blackberry.ui.dialog.CENTER
            });
        } catch (e) {
            alert("Exception in standardDialog: " + e);
        }
    }
    function confirmationPurgeTable(index){
        alert(index);
    }
    

    Sorry, I'm wrong.

    It works, BUT it returns an object.

    Object {return: "Yes"}
    

    So, you'll want to use something like this in your callback function

    function confirmationPurgeTable(index){
       var button = index.return;
    }
    
  • Guest user does not return a value

    I have a user prompt dialog box which is a slightly modified version of questioning the standard user to enter VI express. I tried to change the VI so that it would allow the user to close the command prompt by pressing the enter/return key. The final objective is to have the popup dialog, the user will scan a bar code and barcode reader adds a carriage return, automatic closing of the dialog box character.

    I have followed this user lyrics: https://decibel.ni.com/content/docs/DOC-13973. The only difference between my code and the code it is that my user dialog box returns a string instead of a number. See below for my code.

    The problem that I am running is the string "Item number2" never really returns any value once it's called. The indicator on the front panel of the updated the express vi displays the correct value after you run, but the value is never returned to the VI, who called the dialog box. The express vi the value default value is successfully returned. The only change I made was the addition of the structure of the event, so I have to assume that my code does not go inside this node.

    Any thoughts are appreciated.

    Adjust the chain drive on 'Update value then of the hit'.

  • Need help: not prepared statement to return the value:

    Hi refugees,

    In LICS, prepared statement does not return any value...

    This is the code...

    String p_person_id = pageContext.getParameter ("person_id");

    Connection Conn = pageContext.getApplicationModule (webBean) .getOADBTransaction () .getJdbcConnection ();

    String payment_query = "select max (payment_date) in the xxbdf_payslip_detail_mv where assingment_id = (select assignment_id from the people_reporting_info where person_id ' + p_person_id + ') ';

    PreparedStaement stmt = stmt.executeQuery ();

    ResultSet rs = stmt.executeQuery ();

    While ((rs! = null) & & RS.) Next

    {

    java.sql.Date sql_date = rs.getDate (1);

    SOP (SQL_DATE)

    / * I tried this also * /.

    java.util.Date util_date = rs.getDate (1);

    SOP();

    String string_date = rs.getString (1);

    SOP();

    }

    and I have to format the date as "DD-MM-RRRR.

    Please give your valuable suggestions refugees...

    Thank you

    Jaya

    Jaya Hey,

    Write the code below in the PR

    Code for the prepared statement


    String PaymentData;

    String p_person_id = pageContext.getParameter ("person_id");

    System.out.println ("The person Id is" + p_person_id); check the id of the person should not be null.

    try {}

    Connection Conn = pageContext.getApplicationModule (webBean) .getOADBTransaction () .getJdbcConnection ();

    String query = "select max (payment_date) in the xxbdf_payslip_detail_mv where assingment_id = (select assignment_id from the people_reporting_info where person_id ' + p_person_id + '); '

    PreparedStatement stmt = conn.prepareStatement (Query);

    ResultSet = stmt. ExecuteQuery();

    While (resultset.next ())

    {

    PaymentData = (String) resultset.getString("payment_date").toString ();

    }

    Conn.Commit ();

    }

    catch (System.Exception e)

    {

    e.printStackTrace ();

    }

    See below the Code for the Date Format Conversion


    cabu.ui.validate.Formatter formatter = new OADateValidater (PaymentData, "dd-MMM-YY" "");

    Thank you

    Dilip

  • Hi, actually I want the program stops when you press the stop button. but the problem is the program is runing in loop only he doesn't return tile view deleted complete execution of any body can help me for this.

    Hi, actually I want the program stops when you press the stop button. but the problem is the program is runing in loop only he doesn't return tile view deleted complete execution of any body can help me for this.

    Here

  • Do stuff to PL/SQl that returns the value and redirect to modal page by setting this value

    Hello

    a button click Page1 I would perform a PL/SQL procedure that returns a value in P1_ITEMVAL and then redirect to a page 2 (modal page) and the value of an item on this page with the value previously returned. To do the same thing with a normal page is quite easy:

    Button action is present, then process of PL/SQL that returns the value in the P1_ITEMVAL element and, finally, a branch at page 2 that sets P2_ITEMVAL with P1_ITEMVAL. I really have no idea how to do the same thing when the target is a modal page.

    I created a unit test on https://apex.oracle.com/pls/apex (application 1554 - redir_to_modal)

    Workspace: tests

    USER: supporter

    PWD: supporter1234

    Any help would be much appreciated.

    Kind regards

    Pavel

    Pavel

    If you prepare a URL using the value calculated in the PLSQL of DA part you can then use a subsequent stage of javascript to set the location of the window.

    This will jump to the top of the page of the modal dialog box

    : P1_URL: = apex_util.prepare_url)

    ' f ? p ='|| : APP_ID - Application id

    |': 2' - Page id

    ||': ' || : APP_SESSION - Session id

    ||':'                      -- Request

    ||':NO'                    -- Debug

    : ': ' - Clear Cache

    : ': ' - Settings

    ||' P2_ITEMVAL'

    : ': ' - Parameter values

    || (: P1_ITEMVAL);

    then in the action of javascript

    Window.Location.Replace ($v ('P1_URL'));

    Hope this is of some use

    Concerning

    Kelvin

  • What subprogramme should we prefer to return multiple values with OUT parameter?

    Hello

    I worked on the procedures and functions, and aware of their differences. Today I have an interview question that - suppose I don't have return multiple values through a subroutine and I want nor run any what DML within this subprogramme and I want to use this subprogramme in the SQL query. What subprogramme I would prefer - "Operating Mode" or "Function" and why?

    In my view, both can be used in this case, but want to see your views and opinions.

    Kind regards

    Sachin jerbi

    In terms of software engineering, if you claim something that you expect to "return" something (a value or values) then you use a function.  If you call something to "do" something, and then you use a procedure.

    THE settings are not good practices in many cases and should not strictly considered "return" of values.  Instead, they are assigned values in the code and generally act as pointers to the original variable/structure that was passed as a parameter (the actual internals of Oracle don't quite do it, but in principle this is what they do).

    A return value (or structure) of a function is basically push in the battery to the point that the RETURN statement is issued, and then the code calling the stack appears to assign it to a variable or placeholder, it should go in.

    If it seems a little difference between procedures and functions to some people, it is recommended to use functions for obtaining values and procedures to do things, in most cases.  It is not just "syntactic sugar", as mentioned above.

  • Returns the value of column line

    Greetings!  I currently have a request we will tell

    SELECT value, period FROM MAS_CFUS_KEYACM_CONTROLDATA ORDER BY cf_keyword_ID

    RESULTS

    Period value

    --------------------------

    100.0002 1 JANUARY 14

    -35.68 1 DECEMBER 14

    -1943.67 NOVEMBER 1, 14

    678.0013 OCTOBER 1, 14

    This continues for about 15 results by cf_keyword_ID.

    I'm looking to return the VALUE first in a new column called PREV1, the second value of PREV2, third in PREV3 and so on.  The same goes for the dates.  And all this for only the first 10 values of each cf_keyword_ID.  Can anyone suggest the best way to achieve this?

    Thank you!!

    Hello

    This is called pivoting.  Because I don't have a copy of your table test, I'll use scott.emp to illustrate.

    This shows the first 3 employees for each job, in order by hiredate, along with their hiredates:

    WITH relevant_data AS

    (

    SELECT ename, job, hiredate

    row_number () taken OVER (PARTITION OF work

    ORDER BY hiredate

    ) AS r_num

    FROM scott.emp

    )

    SELECT *.

    OF relevant_data

    PIVOT (MIN (ename) AS ename

    MIN (hiredate) AS hiredate

    FOR r_num (1, 2, 3)

    )

    ORDER BY job

    ;

    Output:

    WORK 1_ENAME 1_HIREDATE 2_ENAME 2_HIREDATE 3_ENAME 3_HIREDATE

    --------- ---------- ----------- ---------- ----------- ---------- -----------

    ANALYST FORD 3 December 1981 SCOTT April 19, 1987

    The CLERK SMITH December 17, 1980, 3 December 1981 JAMES MILLER January 23, 1982

    MANAGER JONES 2 April 1981 BLAKE 1 May 1981 CLARK June 9, 1981

    PRESIDENT KING November 17, 1981

    SELLER ALLEN 20 February 1981 WARD 22 February 1981 TURNER 08-Sep-1981

    There are actually more than 3 SECRETARIES and SALESMEN.  Which does not cause an error; the only first 3 are shown.

    As you can see, having less of 3 does not cause any errors, either.

    For more info on pivots, see the FAQ of the Forum:

    Re: 4. How can I convert rows to columns?

    I hope that answers your question.

    If this isn't the case, please post a small example of data (CREATE TABLE and only relevant columns, INSERT statements) for all of the tables involved and also publish outcomes from these data.

    Explain, using specific examples, how you get these results from these data.

    If yod post rather a problem using scott.emp, then you need not display the sample data; just results and explanations.

    Always say what version of Oracle you are using (for example, 11.2.0.2.0).

    See the FAQ forum:

    Re: 2. How can I ask a question in the forums?

  • When you change an item type only display in hidden element its value changes from any value in value null. Why?


    Dear reading

    When to change a display one item type in the hidden element its value changes from null value any value . Why?

    I would like to use the result of the query in the hidden item, as well as to display it in report footer.

    shortly the displayed element can read footer bu area hidden point cannot be viewved in the footer box. Why?

    footer

    & P11_DISPLAY_ONLY_ITEM.

    footer

    & P11_HIDDEN_ITEM.  )

    (site of apex.oracle.com Application Express 4.2.5.00.08)

    concerning

    Enformatik wrote:

    in the part of the properties point setting its source type as query retune unique value;

    but when you set its value to the calculation (before header) it works correctly.

    It is the expected behavior. The values defined in the properties of the Source element / by default are only put in the controls of the page displayed in the browser, not in session state. To refer to a session-state item value (as in a & P11_HIDDEN_ITEM. substitution of static text) then the value must be set in session state in a calculation or process that runs before the substitution reference is returned.

    Setting the value using a calculation is the right way to do it.

  • Exchange Mail store search reconciliation returns more values

    Hi guys,.

    I ran the calendar "Exchange Mail store search reconciliation" and returned the value of the store of e-mail successfully. Now I run again but not return values. Values existed on the Lookup.ExchangeReconciliation.MailStore has been cleaned.

    I need these values to provision an Exchange user. Is this ok?

    Thank you

    Can you check if the FQDN Admin: cn = oimuser, cn = Users, dc is contoso, dc = com has read access appropriate to the node "CN = Microsoft Exchange, CN = Services, CN = Configuration, dc is contoso, dc = com"?
    You can use any LDAP browser to check if you can register all these entries under this node.

  • How to get AFExecuteThisScript to return the value of Net.HTTP.request (asynchronous)?

    I have an Acrobat only plugin, developed in 2005 VS.  Originally with Acrobat 7 SDK, now updated to use Acrobat 9 SDK.  The ultimate goal of this feature is to open a PDF file from a web server Agile: If a user string, a URL is created, a request sent to the URL, then pay back the answer.  The answer can be either the PDF itself or a string path to the PDF file.  I thought it would be easier to use the version of PDF path to simply open the new PDF of the http:// address.

    I created a folder level javascript with a call to Net.HTTP.request confidence.  I have a script that works when invoked from a menu item added by the folder level javascript file.  But when you use this same command in my C++ with AFExecuteThisScript code, I can't get the HTTP response to finish pending in the code for the result.

    The Net.HTTP.request and the asynchronous callbacks confuse me, so maybe that's my big problem.  I could not Net.HTTP.request to return a value in a service simple javascript right now, I'm trying to use a "global" variable in the JavaScript folder level and two calls.  The first call "sets" the global variable, the other "becomes" it.  But this seems to be the issue.  When I have my code debugging or stop execution, the part of the response of the Net.HTTP.request is never called.  But when I left to go beyond this step with error recovery, the answer appears later.

    So how kick off of the Net.HTTP.request and be notified when it's over?  either in JavaScript or VC ++?

    Any help is appreciated.  Even if the best option is to stream the file from the web server to a local file and then open the (this is the option that I take in another tool that runs outside of Acrobat).

    Here's the code.

    Javascript controls at the level of the files (urls truncated for the post)

    var THE_PATH = '';
    
    function setTHE_PATH ( gURL ) {
        console.println('setTHE_PATH Begin');
        var params =
        {
            cVerb: 'GET',
            cURL: gURL,
            oHandler: 
                {
                    response: function( msg, uri, e)
                    {
                        console.println('response method: Setting Path');
                        THE_PATH = SOAP.stringFromStream( msg );
                        console.println('<<' + THE_PATH + '>>');
                    }
                }
        };
        console.println('URL: ' + params.cURL + '\n  oHandler: ' + params.oHandler );
        console.println('Path: ' + THE_PATH );
        var netResult = trustedNetHTTPrequest(params);
        console.println('setTHE_PATH End');
        return THE_PATH;
    };
    
    trustedNetHTTPrequest = app.trustedFunction( 
        function ( params ) {
            console.println('trustedNetHTTPrequest begin');
            app.beginPriv();
            var netResult = Net.HTTP.request( params );
            app.endPriv();
            console.println('trustedNetHTTPrequest end');
            return netResult;
        }
    );
    

    Added MenuItems with JavaScript at the folder level

    app.addMenuItem( { 
        cName: "mysetTHE_PATH", 
        cUser: "set THE_PATH", cParent: "Tools", 
        cExec: "setTHE_PATH('http://......&getURL=true');",
        nPos: 0 
    } );    
    
    app.addMenuItem( { 
        cName: "mygetTHE_PATH", 
        cUser: "get THE_PATH", cParent: "Tools", 
        cExec: "console.println( THE_PATH );",
        nPos: 0 
    } );   
    

    Here's the JavaScript Console output when you run these two commands:

    setTHE_PATH Begin
    URL: http://......&getURL=true
      oHandler: [object Object]
    Path: 
    trustedNetHTTPrequest begin
    trustedNetHTTPrequest end
    setTHE_PATH End
    response method: Setting Path
    <<https://......DesiredFilename.pdf>>
    

    Here is the function in the plugin C++, with additional measures to prove AFExecuteThisScript works here

    sprintf(jsScript, "testVal='%s';event.value = testVal;", strURL.c_str() );
    AFExecuteThisScript( aPdDoc, jsScript, &pReturnValue );
    // After this, pReturnValue is the passed-in URL, as expected.
    sprintf(jsScript, "setTHE_PATH('%s');event.value = 'Step 1 Worked!!';", strURL.c_str() );
    AFExecuteThisScript( aPdDoc, jsScript, &pReturnValue );
    // After this, pReturnValue is 'Step 1 Worked!!', as expected.
    sprintf(jsScript, "event.value = THE_PATH;", strURL.c_str() );
    AFExecuteThisScript( aPdDoc, jsScript, &pReturnValue );
    // After this, pReturnValue is NULL
    

    This is the JavaScript Console output when you run the commands using the plugin (mode debugger, to wait after step 1)

    setTHE_PATH Begin
    URL: http://......&getURL=true
      oHandler: [object Object]
    Path: 
    trustedNetHTTPrequest begin
    trustedNetHTTPrequest end
    setTHE_PATH End
    

    Note that he never gets to the part of the "method of response.

    Thank you!

    Tim James

    You need not limit yourself to the plugin API. The requests HTTP from C/C++ is a fairly common condition, just observe the restrictions in my answer.

  • Query must return the values null

    Hi once again, everything

    The query below should return zero values for the date, but instead it brings back each transaction in the table, any ideas why?
    SELECT
    
    CID.transaction_id,
    MMT.ITEM_ORD PART_NUMBER,
    CID.DESCRIPTION,
    CID.TRANSACTION_TYPE_NAME,
    CID.LINE_TYPE_NAME,
    CID.SUBINVENTORY_CODE,
    MMT.TRANSACTION_QUANTITY,
    CID.BASE_TRANSACTION_VALUE TRANSACTION_VALUE,
    GLC.SEGMENT1,
    GLC.SEGMENT2,
    GLC.SEGMENT3,
    GLC.SEGMENT4,
    GLC.SEGMENT6,
    TO_CHAR (MMT.TRANSACTION_DATE, 'DD-MON-YY HH24:MI') transaction_date_and_time,
    TRUNC (MMT.TRANSACTION_DATE) transaction_date
    
    
    
    
    FROM
    
    CST_INV_DISTRIBUTION_DAV_V CID,
    MTL_MATERIAL_TXNS_VAL_V MMT,
    GL_CODE_COMBINATIONS GLC
    
    
    
    
    WHERE
    
    CID.TRANSACTION_ID = MMT.TRANSACTION_ID
    AND CID.REFERENCE_ACCOUNT = GLC .CODE_COMBINATION_ID;
    AND MMT.TRANSACTION_DATE = '26-AUG-11 22:00'

    Yes. It's true. You must use TO_DATE to convert a string to a date and you must use TO_CHAR to convert a date into a string.

  • Return the value of the DB display in a Popup Lov (selected)

    Hello

    I use a Popup Lov to select a value and check in the DB (it works), but I do not know how to return this value as selected in the popup Lov and keep the other options available to select again.

    Any ideas?

    Thank you in advance,
    Alan Martini

    Hi Alan,

    OK - keep in mind that this will affect each using the popup LOV page

    Text on the page popup LOV template, under the body of Page attributes, I removed the onload = "first_field ()" let fair: style = "margin: 0;" "

    Then, as part of Page footer text below that, I added:

    <script type="text/javascript">
    var aa = document.getElementsByTagName("A");
    if (aa)
    {
     aa[0].focus();
    }
    </script>
    

    It's just a collection of tags 'A', and if there is at least one, it shifts the focus to the first. My previous SQL makes the value currently selected one in the list, so this should be the same as that. As the item has focus, the user has just need to press ENTER to select this option.

    Andy

  • How to return the value 0 for no data using the County?

    Hi all
    I used this query to count the number of records for each month of the year:

    SELECT DISTINCT COUNT (I.information_sid) COUNT, TO_DATE (TO_CHAR (INSERT_DATE, 'MM'), 'MM') MONTH

    INFORMATION I

    TO_DATE GROUP (TO_CHAR (INSERT_DATE, 'MM'), 'MM')

    ORDER BY TO_DATE (TO_CHAR (INSERT_DATE, 'MM'), 'MM')

    But this code returns no value for months without data
    I want to return the value '0' for any month of data. How, please?

    Note: I use reports 6i.

    Maybe this?

    SELECT SUM(CNT_REC) CNT_REC, MONTH
    FROM
    (
    SELECT COUNT(I.information_sid) CNT_REC, TO_DATE(TO_CHAR(INSERT_DATE,'MM'),'MM') MONTH
    FROM INFORMATIONS I
    GROUP BY TO_DATE(TO_CHAR(INSERT_DATE,'MM'),'MM')
    UNION ALL
    SELECT 0, LPAD(ROWNUM,2,0)
    FROM ALL_OBJECTS
    WHERE ROWNUM <= 12
    )
    GROUP BY MONTH
    ORDER BY MONTH
    

    No need to SEPARATE during the use of GROUP BY.

    -Clément

  • Return a value of a DispatchEvent

    I have a class of the custom event that looks like this:

    package com.ascentify.components.eduspeak.events
    {
         import flash.events.Event;
         
         public class EduSpeakEvent extends Event
         {
              //Build Path Events
              public static const BUILD_PATH:String = "EduSpeakEvent.BuildPath";
              
              public var param:Object;
              
              public function EduSpeakEvent(type:String, pParam:Object=null, bubbles:Boolean=false, cancelable:Boolean=false)
              {
                   param = pParam;
                   
                   super(type, bubbles, cancelable);
              }
              
              public override function clone():Event
              {
                   return new EduSpeakEvent( type, param );
              }
              
              public override function toString():String
              {
                   return formatToString( "EduSpeakEvent", "param", "type", "bubbles", "cancelable" );
              }
         }
    }
    

    This is so I can pass a value with my function.

    In a class of event dispatcher, I have a function that is implemented to ship this event:

    public function buildPath(relativePath:String):Object{
         return dispatchEvent(new EduSpeakEvent(EduSpeakEvent.BUILD_PATH, {relativePath:relativePath}));
    }
    

    It contains lines the problem. I can send a value to the event handler, but I need to return a value as well:

    public function buildPath(e:EduSpeakEvent):String
    {
         var path:String = e.param.relativePath;
                   
         try {
              // If input  is an absolute path or URL, return it.
              if (isAbsolutePath(e.param.relativePath)) {
              return e.param.relativePath;
              }
                        
              // get the current location
              var baseDir:String = ExternalInterface.call("ES_getBaseDirectory");
              displayLoader._trace("baseDir = "+baseDir, true, true);
                        
              // currently, always returns a concatenated path.
              if (e.param.relativePath.charAt(0) != "/" && e.param.relativePath.charAt(0) != "\\")
              {
                   e.param.relativePath = "/" + e.param.relativePath;
              }
              path = baseDir + e.param.relativePath;
              }
         catch (e:Error) {
              var errMsg:String = "[Exception occurred during 'buildPath']: " + e.message;
              displayLoader._trace(errMsg,true,true);
         }
                   
         return path;
    }
    

    Can I get a return on my eventdispatch function value?

    The event system is not designed to return values and you really shouldn't use events to do. Event are for the notification, not function calls. Events can have several listeners, so how could they all return a value? However, if you really want to, your listener could define a field of the event (say event.result) object that you can then interview after the return of dispatchEvent (event).

    BTW, why you go your way as an object rather than a string or anything actually?

    Gordon Smith

    Adobe Flex SDK team

Maybe you are looking for

  • Satellite L500 - failed to initialize webcam

    Webcam always worked... all of a sudden, it will not open and I get the message:+ "failed to initialize the webcam." Please check your device and restart the application or computer. » + The device is what is installed on this Satellite L500 laptop.

  • 8600 more duplex in Word format - no option shows

    I bought this printer for duplex printing, but when I go to print a Word document on my iMac (last version of Word for Mac) and the latest Mac operating system, there is no option for double-sided printing. However, when I looked online for the 8600

  • Library organizes not only optimized files

    I wasn't sure how the title of this question. I have the WD Black ^ 2 double disc in my laptop, and I keep my files on the stretch of 1 tera-bytes of disk. I've linked my libraries in folders on the storage disk; I have the folders on the storage dri

  • The size of the Pavilion HP8565C battery on the motherboard

    I would like to know the number of the stack, which is located on the motherboard of my Pavilion HP8565C desktop computer...

  • Contact the Certification examination test after the accident?

    I'm trying to find out who to contact to have my revised test?  It crashed during my attempt to DCD, and I was actually very shocked to fail, as I was very confident for the majority of the questions.What is the process of having this review?Thank yo