Add or Remove Images
- Last UpdatedJun 10, 2024
- 1 minute read
You can add or remove images in the toolbar. These images are present in:
[AVEVA Work Tasks Installed Path]\AVEVA\Work Tasks\web\BPMUITemplates\Default\WorkItemList\toolbar\Graphics\img path.
To add a new image to the toolbar:
-
Add the following line of code in LoadToolBar() method and based on the user requirement, call the javascript method to call the Custom page. For example, add a new Refresh image in the toolbar.
RadToolbarButton refreshButton = new RadToolbarButton();
refreshButton.CommandName = "Refresh";
refreshButton.ButtonImage = "refresh.png";
refreshButton.Attributes.Add("onclick", "javascript:Callrefresh('" + applicationName + "','" + Actor.Id + "');");
refreshButton.ToolTip = _WorkItemControl.GlobalResourceSet.GetString("Refresh");
refreshButton.ID = "tbrefreshbutton";
toolbar.Items.Add(refreshButton);
Remove an Image from the Toolbar
To remove an image from the toolbar:
-
For example, if you want to remove the Show Queue image from the toolbar, remove the following line of code from the LoadToolBar() method:
RadToolbarButton showQueueButton = new RadToolbarButton();
showQueueButton.CommandName = "Show Queue";
showQueueButton.ButtonImage = "show-queue.png";
showQueueButton.Attributes.Add("onclick", "javascript:CallQueue('" + applicationName + "','" + Actor.Id + "');");
showQueueButton.ToolTip = _WorkItemControl.GlobalResourceSet.GetString("Show queue");
showQueueButton.ID = "tbshowqueuebutton";
toolbar.Items.Add(showQueueButton);