05-21-2012, 11:11 AM
Hi,
Please make sure that the object "dialog" is available in the repository.copy pasting the code will not work with qtp unless we have all the objects in the repository.
The following code
is equivalent to
that explains "with"
Regards,
Ravi
Please make sure that the object "dialog" is available in the repository.copy pasting the code will not work with qtp unless we have all the objects in the repository.
The following code
Code:
With Dialog("Login")
.Activate
.WinEdit("Agent Name:").Set "nisha"
.WinEdit("Agent Name:").Type micTab
.WinEdit("Password:").SetSecure "4fb9c587cc4d77b45a24542b5db06399cf49cc89"
.WinEdit("Password:").Type micReturn
End With
Code:
Dialog("Login").Activate
Dialog("Login").WinEdit("Agent Name:").Set "nisha"
Dialog("Login").WinEdit("Agent Name:").Type micTab
Dialog("Login").WinEdit("Password:").SetSecure "4fb9c587cc4d77b45a24542b5db06399cf49cc89"
Dialog("Login").WinEdit("Password:").Type micReturn
Regards,
Ravi