Opening TGML Diagrams from TGML components
You can open a TGML diagram from a TGML component. This topic uses an example to illustrate how you can configure a TGML component to open a TGML diagram.
To open a link from a component:
- Open the Graphics Editor: Go to Start > Power Monitoring Expert > Graphics Editor.
- At the bottom left, select Components.
- Expand the Basic Controls tab, and then drag and drop the Button component to the workspace.
- At the bottom left, select Snippets, and then drag and drop Pop-Up onto the Button component in the workspace.
- At the bottom right, select Objects.
- Define the Link attribute value:
- Expand the Definitions > Component node to find the Link attribute within the button.
- Double-click on Link > Object, and then enter the TGML file name without the extension. Fr example:
tgml\Test 1
. - Select Save to save the TGML file.
Button TGML components have a built-in snippet script for opening either in the same tab or in a new window. You don't need to add additional snippets over the button TGML components. Instead, select any button component and under the Link Name property, if the button definition is Open New Window, enter the URL of file you want to open. And, for all other button components, either give the TGML file name that you want to open on the select event of that button. For example: tgml\Test1 or the URL of the file.
NOTE: If the TGML file is placed in another folder inside the tgml folder, then you need mention all the folder names before the file name using the following format: ...tgml\<sub-folder name>\TGML file name
. For example: ...tgml\My TGML\Test1
. Refer to the following image:
To test the changes:
- Go back to PME Web Applications page that was already open, and then refresh the page.
- Select the saved TGML file in the Diagram Library menu.
- Select Button.
URL saved graphic file name is displayed in the Diagram Library menu.
The following screen is displayed:
The following screen is displayed with the linked URL in a Pop-Up: