hp-uft

ObjChildItem.Click() not working properly in a loop

可紊 提交于 2020-05-16 22:01:43
问题 I am using UFT One to test a Salesforce Contacts table with two rows that have clickable links, "Jim Bean" and "Marsha Smith". (see attached image). I want to loop through the rows and click on the links and have "ValidateContactProperties" Action get called for each Contact Details page that comes up. The following code works but ObjChildItem.Click() gets executed only the first time. Only Jim Bean's contact profile page is displayed, not Marsha Smith's. For i = 2 to rowCount Set

ObjChildItem.Click() not working properly in a loop

岁酱吖の 提交于 2020-05-16 22:01:36
问题 I am using UFT One to test a Salesforce Contacts table with two rows that have clickable links, "Jim Bean" and "Marsha Smith". (see attached image). I want to loop through the rows and click on the links and have "ValidateContactProperties" Action get called for each Contact Details page that comes up. The following code works but ObjChildItem.Click() gets executed only the first time. Only Jim Bean's contact profile page is displayed, not Marsha Smith's. For i = 2 to rowCount Set

How to connect to oracle database using VBScript and UFT?

為{幸葍}努か 提交于 2020-04-14 07:35:12
问题 It seems the question on how to connect to oracle database from UFT/VBscript is asked on multiple forums. In most places, there are answers in bits and pieces, without any one detailed answer that helps user get this information. I spent close to 6 days to get this working and thus I feel its worth to share all the detailed steps here. The main reason I found this for going wrong is a wrong combination of one or more of below: Using the wrong driver. Using the wrong connection string. Using

How to get Test variable through custom code in HP UFT - ApiTest

心不动则不痛 提交于 2020-01-23 17:28:06
问题 I want to set value to the Test Variable using Custom Code. Can you tell me how to do it as i am not able to access the variable from code. I need to access the User Variable URL in my custom code and set the value. Please help me if you know how to do it using Custom Code. Thanks, Madhan 回答1: Based on your question: 1. Click on File menu and then Settings, it will open Properties pane. 2. Click on "+" to add user variable and give a name. 3. In your custom code, type below code: string s =

SystemUtil.Run in UFT gives me “invalid procedure call or argument”, Why?

≡放荡痞女 提交于 2020-01-07 03:57:07
问题 I'm using SystemUtil.Run (pathName) in UFT, VBScript. But it gives me invalid procedure call or argument. I'm sure about pathName, I'm sure about the command, I'm sure about everything. What do you think might be the cause? 回答1: If you look at the examples here, you'll see that the approved call is SystemUtil.Run pathName (passing pathName per reference) instead of SystemUtil.Run (pathName) (passing a const copy). Eric Lippert's essay should help you to understand the use of () in VBScript.

Loop all the rows of a worksheet and copy them into a blank sheet

本秂侑毒 提交于 2020-01-06 15:49:26
问题 I'm facing a serious problem while importing my script into UFT for more than 2 weeks, I tried everything. As a worarround, I'm cpying the workbook and then I import the new on but this sometimes doesn't work too. this is my code: DataTable.ImportSheet workbook1,"name1","sheet1" this is my workarround: On error resume next DataTable.ImportSheet workbook_path,"name1","sheet1" MsgBox "Error: " & Err.Number & " (" & Err.Source & ") - " & Err.Description If Err.Number <> 0 Then If err.number =

Automate tests on virtual machine without graphical session

巧了我就是萌 提交于 2020-01-04 14:12:24
问题 Context : I execute automated GUI tests on virtual machines (there are few of them) on running on windows and using UFT/Ranorex, executions are piloted by Jenkins. Problem: VM must have an active graphic session, otherwise, UFT won't run GUI tests (unable to launch browser) and Ranorex will run but poorly and without screenshots. i mean that in my tests, the VM is configured not to "sleep" or to have any screen saver, vm is connected with jenkins properly. The behavior is : i launch via

Get dates from AUT?

自作多情 提交于 2019-12-30 11:48:48
问题 My Web-based application (like most) follows the browser locale to format dates. So if you configure British English as the preferred language in the browser, the app will display dates in " DD/MM/YYYY " format. Now QTP (ok, it´s VBScript that is the culprit) does not know about this. It strictly follows the local machine´s locale settings. Unfortunately, that means that if my local machine is configured to German locale, and the app is in English (because the browser is configured this way),

Facing Build Error:“No agent found in pool Default which satisfies the specified demands: UFT_LAUNCHER” while running UFT Tests from VSTS Build

随声附和 提交于 2019-12-25 10:32:03
问题 Installed Unified Functional Testing Extension on VSTS from Market Place.Have downloaded a Private Agent on Windows from Agent Pool, while selecting the Default Agent Queue and queuing the Build, Facing a below Error :- "No agent found in pool Default which satisfies the specified demand:UFT_LAUNCHER" Agent.Version -gtVersion 1.98.1 I want to run my UFT Scripts in VSTS and then Publish Reports corresponding to Test Scripts created in Test Hub,I am getting failed at First Step. Note: I have

Facing Build Error:“No agent found in pool Default which satisfies the specified demands: UFT_LAUNCHER” while running UFT Tests from VSTS Build

爱⌒轻易说出口 提交于 2019-12-25 10:31:18
问题 Installed Unified Functional Testing Extension on VSTS from Market Place.Have downloaded a Private Agent on Windows from Agent Pool, while selecting the Default Agent Queue and queuing the Build, Facing a below Error :- "No agent found in pool Default which satisfies the specified demand:UFT_LAUNCHER" Agent.Version -gtVersion 1.98.1 I want to run my UFT Scripts in VSTS and then Publish Reports corresponding to Test Scripts created in Test Hub,I am getting failed at First Step. Note: I have