Show Web Page in iframe
This application registers a ShellUI module that reacts when users select items in the listings and searches for the object title on Microsoft Bing.
This application is only compatible with M-Files Desktop.
- The application consists of three files:
appdef.xml, which declares the application contents.
main.js, a ShellUI module, which creates the tab and reacts as items are selected in the listing.
dashboard.html, the dashboard shown in the tab. The dashboard contains an iframe which is shown full-screen, and renders the website within it.
The application broadly takes the following approach:
- When the shell frame is started, the code registers a new tab.
- When the selected items are changed in the active shell listing, the currently-selected items are passed to the dashboard.
- The dashboard iterates over the selected items, builds up a search string, and alters the
srcattribute of the
iframeto execute the search.
Testing and deploying
The simplest method to test an application is to copy the files into a local development folder. This allows you to alter the files and simply log out and into the vault to see the changes.
To deploy the application, you must zip the application files and deploy them using the M-Files Admin tool. This process is detailed on the M-Files Developer Portal.
When a client connects a vault, new User Interface Extensibility Framework applications will be downloaded and the user will be prompted to install them. This can be avoided by pre-approving it using registry keys.