• Resolved girard176

    (@girard176)


    Hi,

    I’m trying to embed an excel file from onedrive with the following Javascript :
    <div id=”myExcelDiv” style=”width: 700px; height: 377px”></div>
    <script type=”text/javascript” src=”https://r.office.microsoft.com/r/rlidExcelWLJS?v=1&kip=1″></script&gt;
    <script type=”text/javascript”>
    /*
    * This code uses the Microsoft Office Excel Javascript object model to programmatically insert the
    * Excel Web App into a div with id=myExcelDiv. The full API is documented at
    * https://msdn.microsoft.com/fr-FR/library/hh315812.aspx. There you can find out how to programmatically get
    * values from your Excel file and how to use the rest of the object model.
    */

    // Use this file token to reference Weight to HP.xlsx in Excel’s APIs
    var fileToken = “SD601E4D5C3EF598BF!215/6926058335531014335/t=0&s=0&v=!ABBpbK18hguDBgw”;

    // run the Excel load handler on page load
    if (window.attachEvent) {
    window.attachEvent(“onload”, loadEwaOnPageLoad);
    }} else {{
    window.addEventListener(“DOMContentLoaded”, {6}, false);
    }}

    function {6}() {{
    {7}

    Ewa.EwaControl.loadEwaAsync(fileToken, “myExcelDiv”, props, {8});
    }}

    function {8}(result) {{
    /*
    * Add code here to interact with the embedded Excel web app.
    * Find out more at {3}.
    */
    }}
    </script> else {
    window.addEventListener(“DOMContentLoaded”, loadEwaOnPageLoad, false);
    }}

    function {6}() {{
    {7}

    Ewa.EwaControl.loadEwaAsync(fileToken, “myExcelDiv”, props, {8});
    }}

    function {8}(result) {{
    /*
    * Add code here to interact with the embedded Excel web app.
    * Find out more at {3}.
    */
    }}
    </script>

    function loadEwaOnPageLoad() {
    var props = {
    item: “‘Feuil1’!A1:D10”,
    uiOptions: {
    showDownloadButton: false,
    showGridlines: false,
    selectedCell: “‘Feuil1’!D3”,
    showParametersTaskPane: false
    },
    interactivityOptions: {
    allowParameterModification: false,
    allowSorting: false,
    allowFiltering: false,
    allowPivotTableInteractivity: false
    }
    };

    Ewa.EwaControl.loadEwaAsync(fileToken, “myExcelDiv”, props, onEwaLoaded);
    }}

    function {8}(result) {{
    /*
    * Add code here to interact with the embedded Excel web app.
    * Find out more at {3}.
    */
    }}
    </script>

    function onEwaLoaded(result) {
    /*
    * Add code here to interact with the embedded Excel web app.
    * Find out more at https://msdn.microsoft.com/fr-FR/library/hh315812.aspx.
    */
    }}
    </script>
    </script>

    When I create my code and name it CODE1 and saving it, I can’t manage to have it shown in the page. The only thing I’m seeing is the %CODE1%.

    Any idea?
    Thank you very much!

    https://www.ads-software.com/plugins/simple-embed-code/

Viewing 6 replies - 16 through 21 (of 21 total)
Viewing 6 replies - 16 through 21 (of 21 total)
  • The topic ‘Only %CODE1% showing in page’ is closed to new replies.