How to open an external file in Reliance SCADA using a Button component
December 9, 2016 | Reliance SCADA
Sometimes – in either Reliance's runtime software or thin clients – an external file (document, table, etc.) must be opened. There are several options how to do that, but we recommend that you use an action of type Run application (do not forget to select a path to the file) and, for example, a Button component to which the action must be linked.
What to do
- First of all, put the file in your project's ThinClients directory (e.g., C:\Users\Hostname\Documents\Reliance4\Projects\ProjectName\ThinClients\Doc\MyDoc.pdf).
- Open Reliance Design's Action Manager and create a new action of type Run application. In the Application file field, enter the address as follows: http://Hostname:40000/Doc/MyDoc.pdf. If the file is located on the Internet, enter the file's URL address.
- In Reliance Design, insert a Button component into the visualization window. On the Scripts/Actions page of the component's Properties dialog box, activate the Execute action on click > Left button option and select the action (in our example, we have chosen an action named Open_External_File).
- Save the visualization project. If Reliance's thin clients (Smart Client or Web Client) are part of your project, it is essential that you export the project for remote users again (the Re-export for Remote Users command).
- The end user's computer must be equipped with a PDF viewer.
- The URL address must include a protocol (HTTP or HTTPS), hostname, and port number.
- Please note that the hostname is hardcoded in the project. So, if you move the project to another computer, the action will not work.
- Alternatively, you can put the PDF file on an Internet server.
Haven't found what you were looking for? Use this form to inform us about it.