EV Observe - Synthetic Monitoring Module - Scripts

Last modified on 2023/09/28 16:51

Once recorded, scenarios are available on machines. You can then:

  • Display of the desktop action by action as thumbnails fashionable PowerPoint.
  • Add/remove actions in offline mode (images, OCR, etc.).
  • Filter on user actions.
  • Export the scenario in Word (.docx) format.
     

Scenarios are accessible from the Scripts menu of the Scripts Manager tool or directly via the Systray.

Description of the screen

The screen is made up of the following zones:

          Scripts with areas.png

Toolbar

          Scripts - Toolbar.png

  • Create a new scenario.
  • Rename a scenario.
  • Save and recompile a scenario.
  • Copy a scenario.
  • Undo/Redo.
  • List of available scenarios: You can apply a search filter.
  • Load the selected scenario.
  • Reload the current scenario.
  • Properties of the current scenario. Open url.png See the description
  • Load the current scenario in Visual Basic.
  • Export the current scenario in Word format.
  • Type of screenshot display (small or large).
  • Display the scenario depending on the type of display selected.
  • Restore old scenario versions: You can recover a backup based on the backup date and the version of the software that recorded and compiled the scenario.
     

Type of screenshot display
The loaded scenario can appear in:

  • Small mode: All desktop screenshots taken during scenario recording are displayed in the central panel as thumbnails.
          Scripts - Small mode display.png
  • Large mode: Each screenshot is displayed individually with associated actions in the left panel. Move on to the next thumbnail by clicking on Next slide icon.png.
          Scripts - Large mode display.png

Tree structure

          Scripts - Tree structure.png

The tree contains all user actions for the selected scenario, grouped by type, as well as the scenario library.

  • Scenario actions:
    • Windows objects.
    • Image actions (click, double click, etc.).
    • OCR actions (character recognition).
    • Mouse movements.
    • Keyboard entries.
    • Transactions.
    • Variables.
    • Subroutines.
  • The library: It contains all actions and subroutines that can be shared with other scenarios.
  • Killprocesses: When a scenario fails, all created Windows processes and/or windows are killed. The KillProcess line displays all the kill actions which will be performed in case of error.
  • Commented lines.

List of user actions

The panel displays all the user actions linked to the selected scenario, such as click on image, mouse movements, keyboard inputs.

  • You can filter the actions in the tree structure, such as Image, OCR.
  • You can add or change pictures, add intermediate transactions, etc., using the offline mode.

          Scripts - Action list.png

Action properties

          Scripts - Action properties.png

The central panel displays the contextual properties of the selected user action.

     Open url.png See the description for an image action

Display of the desktop

During the recording of the scenario, a screenshot of the desktop is taken to each user action. It appears in the form of a thumbnail in the right panel.

  • You can navigate through the scenario to display the graphical state of the desktop for each action.
  • Click on Next slide icon.png to go to the next actions.
     

example  LeftDoubleClicImage action

  • The desktop icon on which a double-click is performed is surrounded in red.
  • The search area on the icon in the Firefox case is surrounded in green. By default, 300 pixels from the original position.
  • Click on Next slide icon.png to go to the next action: When Firefox is launched, the script searches the entry bar to enter the URL.

          Scripts - Desktop 1.png
         Scripts - Desktop 2.png

Properties

Properties of a scenario

Access: Click Properties icon.png in the toolbar

   The values are default values that apply to all actions of the scenario. You can edit properties of a specific action by clicking on it.

          Scripts - Scenario properties.png

 

  • Behavior:
    • KeyMenuCode_Play: Function key to stop the recording of the scenario (by default, <F8>).
    • KeyShowPlayer: Function key to put in the foreground the recorder and/or player (by default, <F9>).
    • OnError: indicates what the scenario should do in the event of an error.
      • Kill_End: Delete all Windows processes and/or windows created during the recording, by executing the KillProcess() function.
      • End_: No action is taken and the process and/or Windows windows remain as they are.
      • Learning: Stop the scenario on the error and give control back to the user.
  • DataSets: The Dataset file is a file in CSV format located in the
    C:\ProgramData\Itexis\Components\Scripts\ScriptName\Datasets directory.
    • DataAcessType: File access mode.
      • Sequential: Sequential entries.
      • Random: Randomly entries.
    • DataLockType: File lock mode.
      • Dynamic: Access to file blocked during each iteration of script execution. Once finished, access is available again.
      • Static: Access to the file is no longer possible until the next ClearSet.
    • DataSetName: Name of the Dataset file. There may be several per scenario.
    • GlobalDataset: Indicates whether the Dataset file is local (one file on each machine - option False) or global (one common file on the parent machine - option True).
  • Environment: Graphic resolution used when recording the scenario.

   You must replay the scenario in the same resolution.

  • Images Capture:
    • Precision: Value (in percentage) of the minimum shape accuracy between the image recorded when the scenario was saved and the image captured when the scenario was run.
    • ScanAreaPixel: Default size of image search area.
  • Mail:
    • AlarmTime: Send an alert by email if the scenario execution time exceeds x % of the reference time (if 0, no email is sent).
    • MailBcc: Email addresses in Blind Carbon Copy.
    • MailCc: Email addresses in Carbon Copy.
    • MailEvent: Condition to send alerts by emails.
      • Never: No email is sent.
      • OnAlarm: Send an alert by email if the scenario execution time exceeds x % of the reference time (AlarmTime value) and/or if the scenario falls into error.
      • OnError: Send an alert by email if the scenario falls into error.
      • Always: Send an alert by email after each iteration of scenario execution.
    • MailFrom: Email address of sender.
    • MailSMTPServerAdress: SMTP server address for sending by SMTP client to Agent.
    • MailTo: List of email recipients.
    • NumAlarms: Send an alert by email after x iterations of scenario execution in error.
    • SenderName: Name of sender.
    • SenderType:
      • SendFromDatabase: Email sent from the email address of the database client (You must configure it).
      • SendFromAgent: Email sent from the email address of the Agent.
  • Misc:
    • SNMPVersion: SNMP version used (v1 to v3).
  • OCR Capture:
    • ScanOCRHeight / ScanOCRWidth: Rectangle size for string search area.
    • ToleranceOCR: Tolerance accepted for the search, in number of characters.
  • RecordMode:
    • Record Mode: Script recording mode, which can be Basic (automatic recording) or Advanced (manual recording).
  • Run Time:
    • Acceleration: Rate (in percentage) of scenario recording speed (100%, 200%, etc.)
    • TimeOut: Waiting time (in milliseconds) before the scenario goes into error.
    • UserWait: Indicates whether the scenario takes the user's waiting time into account (True option) or not (False option).
  • Script:
    • DateCreated: Scenario creation date.
    • DateLastUpdate: Date of last compilation.
    • Description: Free field for comments.
    • GroupName: Name of the group to which the scenario belongs, used for additional statistics.
    • NewReferenceTime: Forces recalculation of a new reference time the next time the scenario is run (True option).
    • SaveLogOnDatabase: Indicates where metrics are stored.
      • OnDatabase: Metrics are stored in the database.
      • OnCsv: Metrics are stored in the CSV file.
      • Never: No metrics are stored.
    • ScriptName: Name of the scenario.
    • Step By Step: Forces Advanced mode (manual recording) the next time the scenario is run (True option).
    • TotalReferenceTime: Reference time of scenario execution.
  • SNMP:
    • SendSNMPTraps: Indicates whether the scenario should send SNMP traps (True option) or not (False option).
    • SNMPAlarmTime: Send an alert by SNMP trap if the scenario execution time exceeds x % of the reference time (if 0, no email is sent).
    • SNMPCommunity: SNMP community, which can be Public or defined by the user.
    • SNMPContact: SNMP contact.
    • SNMPEvent: Condition to send alerts by SNMP trap.
      • Never: No alert is sent.
      • OnAlarm: Send an alert by SNMP trap if the scenario execution time exceeds x % of the reference time (AlarmTime value) and/or if the scenario falls into error.
      • OnError: Send an alert by SNMP trap if the scenario falls into error.
      • Always: Send an alert by SNMP trap after each iteration of scenario execution.
    • SNMPGenericTrap: True/False.
    • SNMPListenPort: SNMP listening port. By default, 161.
    • SNMPNumAlarms: Send an alert by SNMP trap after x iterations of scenario execution in error.
    • SNMPTrapManager: SNMP IP address. By default, 127.0.0.1.
    • SNMPTrapPort: SNMP port. By default, 162.
  • Transactions:
    • SaveTransactionScreenShot: Indicates whether transaction screenshots should be saved (option True) or not (option False).

Properties of an Image action

Access: Click on an Image action in the list of actions

          Scripts - Action properties.png

  • Line: Number of the image in the scenario timeline.
  • Key Object: Key of the object if the Tracking Object option is enabled (option defined in the settings Recorder).
  • Anchor ID: Anchor ID when there is an an anchor on the image.
  • Action: User action associated with the image.

example  LeftDoubleClickImage action

  • User Wait: Waiting time (in milliseconds) between the moment the image is found and the action mouse on it.

   You may need to increase the waiting time: in Windows environments, some of the images/icons displayed are not ready to receive a mouse action (due to Windows latency).

  • Precision: Minimum accuracy required to accept the image via shape recognition.
    • The precision must be close to 90% of the one taken during the scenario.
    • 100% corresponds to a perfect recognition.
  • Timeout: Timeout of the algorithm to find the image.
    • After this timeout, the script leaves in error or in a subroutine.
  • Scan Area: Search area to find the image.
    • By default, 300 pixels.

Predefined Visual Basic functions

     Open url.png See the procedure.

  • Citrix functions:
    • CitrixGetServerName(): Retrieve from the database the name of the Citrix server that delivers the session service.
    • CitrixLogoff(): Properly close the Citrix session on the server and terminate the session process.

   The Citrix features must be installed. Open url.png See Citrix features installation.

  • RdsLogoff(): Properly close the RDP/RDS session.
  • Sleep functions:
    • Sleep (1000): Wait for a second before continuing the scenario.
    • Sleep (1000,2000): Wait for a random time within a range.

   The default waiting times can be changed.

  • KillProcess ('ProcessName'): In case of error, allows to execute the 'ProcessName' process to delete all Windows processes and/or windows created during the scenario.
    • The 'ProcessName' process contains all kill actions which will be performed in case of error.
             Settings for other actions - Insert action - VB code KillProcess.png
  • ProcessStart ('ProcessName'): Request for starting a process.
  • Wait cursor functions:
    • WaitCursorApppears: Wait for a specific cursor shape to appear with a timeout.
    • WaitCursorDisappears: Wait for a specific cursor shape to disappear with a timeout.

Open url.png See the procedure to find out the cursor shape.

Tags:
Powered by XWiki © EasyVista 2024