Example 1: “Demo Template”

This is an example how I use the Rumba addon. In real, I use this code in 4 files, one to open Rumba, one to go to specific mainframe application, one to leave a mainframe application and one to close Rumba. In this case, they are all combined:

'Open Rumba session, if not already open

WDOpenRumba("C:\Users\XXX\Desktop\QTP TE.WDM")

'Before beginning, set the system path if required

'SystemPath = "C:\Program Files (x86)\WallData\SYSTEM"

'Wait a short while for the program to start and settle


'Open connection with the first opened session.

'It is not recommended to open multiple sessions


'For this application, the use of sendkeys worked the best.

'But normally SetText would be used.

'First sendkeys to go to the signon screen


'Wait for the cursor is set to the user-id field

WDWaitWhile(WDGetPos(18, 26))

'Now fill in the UserID and PSW


WDWaitWhile(WDGetPos(19, 26))


'Wait till subsystem selection screen is appeared

'and then select option 2

WDWaitWhile(WDGetPos(1, 28), "Subsystem Selection")


'Wait till Production Activity Account screen is active

WDWaitWhile(WDGetPos(1, 26), "Production Activity Account")

'For fun, place the screen text to output

output = WDGetText()

'For fun, search text on screen

Status = WDSearch("Production")

'Exit by pressing F3


'Wait till subsystem selection screen is appeared and then select F3 again

WDWaitWhile(WDGetPos(1, 28), "Subsystem Selection")


'Wait a short while for the program to end Rumba and settle

WDWait (1000)

'Close connection with session


'Close Rumba

WDCloseRumba("C:\Users\XXX\Desktop\QTP TE.WDM")

Created with the Personal Edition of HelpNDoc: Easily create PDF Help documents