Adding Context Menu Items

Context menu items are actions that are displayed to the user when he/she right-clicks on something. Alternatively referred to as local, shortcut or right-click menu items, they can be interrogated and included in Studio automations, for windows and web-based applications.

When using context menu items in Studio automations you must include in the automation a method that causes the context menu to display. Common methods used to open a context menu are PerformRightClick and ShowContextMenu. Always try PerformRightClick first as it is a method most often recognized by applications.

Follow these steps to add a context menu item to a Studio  solution:

  1. Start Interrogation of the target application.

  2. Interrogate the target application control/object, such as a list box or data grid, associated with the context menu you want to include in your solution.

  3. Without stopping interrogation of the target application, change focus to Object Explorer.

  4. In Object Explorer, right-click the target application window object and select Add Context Menu Items from the Context menu, or, from the Windows tab, highlight the target, right-click and select Add Context Menu Items.

  5. Change focus back to the target application, and right-click to open the context menu you want to interrogate..

  6. Instead of the context menu opening, the Add Context Menu Items dialog displays populated with the context menu items.

  7. Select the check boxes for the context menu items you want to include in your solution and then close the dialog to save your selections. An example of the Add Context Menu Items dialog is shown here, with menu items selected.

The selected context menu items now appear in Object Explorer and the associated properties, methods, and events can be incorporated in your automations.

  1. Stop the interrogation.

 

 


Privacy | Trademarks | Terms of Use | Feedback

Updated: 18 June 2020

© 2016 - 2020 Pegasystems Inc.  Cambridge, MA All rights reserved.

 

OpenSpan data classification label