Skip to content

Excel Add-inShow an app in Excel's task pane and read and write the workbook.

abap2UI5 addons

What it does ​

An Office add-in that opens an abap2UI5 app in the task pane of Microsoft Excel: the real abap2UI5 UI5 frontend, served by your SAP system through a host page in the BSP Z2UI5_XL. The app stays an ABAP class and talks to the workbook through the custom control z2ui5.cc.ExcelBridge, which writes tables into sheets and reads selected cells. The repository holds the host page, a demo app, the manifest generator and the tests. It is a proof of concept: CI tests it against a stand-in for Office.js, nobody has run it in a real Excel yet.

Requirements ​

  • abap2UI5 1.147.0 or later (the first release with z2ui5.cc.ExcelBridge)
  • The embed control needs abap2UI5 1.145.0 or later
  • NetWeaver 7.02 - 7.40: the downported branch 702
  • UI5 1.71 or later on the system; theme sap_horizon needs UI5 1.102+, else --theme sap_fiori_3
  • HTTPS with a certificate the users' machines trust
  • Excel: Microsoft 365, Excel 2019 or later on Windows or Mac, Excel on the web best effort (ExcelApi 1.4)
  • ABAP Cloud: no BSP applications, pull only src/01 and serve the host page without a BSP
  • Node.js 22 for npm run manifest

Installation ​

With abapGit, from the repository:

  • Pull with abapGit into a package of its own (for example $Z2UI5_XL) on the system that runs abap2UI5; it brings Z2UI5_CL_XL_DEMO, the BSP Z2UI5_XL and the ICF nodes /sap/bc/ui5_ui5/sap/z2ui5_xl and /sap/bc/bsp/sap/z2ui5_xl
  • In SICF check that /sap/bc/ui5_ui5/sap/z2ui5_xl is active with the same logon settings as /sap/bc/z2ui5
  • Try it in a browser first: https://<sap-host>/sap/bc/ui5_ui5/sap/z2ui5_xl/index.html?app=Z2UI5_CL_XL_DEMO
  • Write the manifest with npm run manifest -- --host https://my.sap.example --app Z2UI5_CL_XL_DEMO --client 100 --out manifest.xml and deploy it to users
  • For Excel on the web set the frame-ancestors and SameSite cookie headers on the system

The Guide has every step.

A first app ​

abap
page->tag( n = `ExcelBridge` ns = `z2ui5`
    )->a( n = `id`               v = `excel`
    )->a( n = `rows`             v = client->_bind( materials )
    )->a( n = `columns`          v = client->_bind( columns )
    )->a( n = `target`           v = `newSheet`
    )->a( n = `sheetName`        v = client->_bind( sheet_name )
    )->a( n = `selection`        v = client->_bind( selection )
    )->a( n = `selectionAddress` v = client->_bind( selection_address )
    )->a( n = `OnWritten`        v = client->_event( val = `XL_WRITTEN` arg = `${$parameters>/address}` )
    )->a( n = `OnRead`           v = client->_event( val = `XL_READ` arg = `${$parameters>/address}` )
    )->a( n = `OnError`          v = client->_event( val   = `XL_ERROR`
                                                     t_arg = VALUE #( ( `${$parameters>/message}` )
                                                                      ( `${$parameters>/code}` ) ) ) ).