hp-uft

UFT not identifying a window in some playback

一个人想着一个人 提交于 2019-12-24 17:23:15
问题 I am using descriptive programming in UFT. During playback, I want to check if the Windows print dialog does appear. Then I want to click the Cancel button in that dialog. My problem: Sporadically QTP fails to identify the printing dialog, so clicking on the cancel button fails. How can this possibly sometimes fail, sometimes succeed? My code syntax given below: Set Window_EnterMeter = browser_servicemanager.Window("regexpwndtitle:=Enter Meters.*") Set dialog_Print = Window_EnterMeter.Dialog(

Getting error “ActiveX component can’t create object” when running testset

元气小坏坏 提交于 2019-12-24 15:24:47
问题 I'm trying to run UFT script from ALM using VBScript, but I'm getting an error on the line: set objScheduler = objTestSet.StartExecution (""). Error:ActiveX component can’t create object Full script: ' Script : Run the ALM/QC Test Sets Dim objTDCon, objTreeMgr, objTestSetFolder, objTestSetList Dim objTestSet, objScheduler, objExecStatus, objTestExecStatus Dim strTestSetFolderPath, strTestSetName, strReportStatus, intCounter 'Declare the Test Folder, Test and Host you wish to run the test on

Open QTP (UFT) Using Java Script using Chrome

久未见 提交于 2019-12-24 10:28:51
问题 The following is the code I used to launch qtp, It is working well with IE but not in chrome. What are the changes I shd Make to open through Chrome var qtApp = new ActiveXObject("QuickTest.Application"); qtApp.Launch(); // Start QuickTest qtApp.Visible = true; 回答1: Microsoft's VBScript is integrated with COM and UFT also exposes a COM interface, this is why you were able to launch UFT from HTML using VBScript. However VBScript is not supported by Chrome and JavaScript is not integrated with

How to select specific element in Powerbuilder window using HP UFT

╄→尐↘猪︶ㄣ 提交于 2019-12-24 09:10:12
问题 I am trying to record/automate an application developed in Sybase' Powerbuilder. I am currently using HP UFT v12.54. Using the default recording process, the object spy is only seeing the area on my PB Window, not the specific field/dropdown. In short, I am unable to select a specific object in the window. Please see the following image: I am trying to select the Authorized Signatory field, but instead, UFT does not see the specific element, but the field area Customer Data instead. UFT just

QTP UFT Unable to find row count from table

◇◆丶佛笑我妖孽 提交于 2019-12-24 01:24:05
问题 I was not able to find row count of that table and when I spy, Object Respository doesn't show any webtable. Can you please help me on how to find the row count. It was developed in Angular Js framewrok. Attached Object Repsoitory: The DOM 回答1: The elements in the screenshot do not contain a TABLE element (only DIV s). Try running (in the browser's developer tools) document.getElementsByTagName('table') if it returns an empty set then this is the reason UFT isn't showing you a table. UFT does

HP-UFT WPF TextBlock object capture

耗尽温柔 提交于 2019-12-24 00:57:41
问题 I am working on a WPF application where we have to automate testing. This work fine for many components but we struggle to check a summary page where we use TextBlock to display our data. The WPF TextBlock is not found by the HP tool. Thus we cannot check the values that we display. We tried the following solutions but without success: Change x:Name in Name (not the best idea right, but we tried all!) AutomationProperties.AutomationId on the TextBloc AutomationProperties.Name Make the

How to import data from excel to UFT based on condition

↘锁芯ラ 提交于 2019-12-23 22:18:39
问题 I have an excel sheet which contain data for test cases and each test cases is separated by a column value say script ID and i want to load only row where script ID =1 . How we can achieve this with DataTable.ImportSheet method as this method import all the row having script id=2 and 3 I also try with query string and that is working fine , but i want to achieve this by DataTable.ImportSheet method (project constraints) Thanks Aman 回答1: You can also do it by creating data table first manually

Integer and String comparison conflict in VBScript

坚强是说给别人听的谎言 提交于 2019-12-23 18:02:26
问题 The below VBScript code while trying to run in HP-UFT confused me because the first statement prints True instead of False (which does not seem logical), while the second one prints False (which seems logical) Code: print 40 = "40" a = 40 b = "40" print a = b Output: True False 回答1: It's perfectly logical ( cough ), there is only one data type in VBScript and that is Variant . However VBScript can handle many different sub types of the Variant data type. When you compare 40 = "40" VBScript is

How to Zoom in or Zoom out in a webpage while using UFT/QTP

為{幸葍}努か 提交于 2019-12-21 06:04:13
问题 I would like to control the zoom in and out feature of my webpage of the application under test using UFT. This is required as the zoom level changes dynamically and it becomes difficult to identify the objects. I have found a code but it is useful if you need to change the zoom level at one instance or at the start. below is the code Function ChangeIEZoom Dim intZoomLevel, objIE intZoomLevel = 110 Const OLECMDID_OPTICAL_ZOOM = 63 Const OLECMDEXECOPT_DONTPROMPTUSER = 2 Set objIE =

How to import data file for UFT API testing?

柔情痞子 提交于 2019-12-20 05:11:37
问题 I am working on a project which requires to dynamically import the test data on run time and run the API test corresponding to the test data. I tried using XMLload which I directly load from the xml request. This seems to be working fine. But like GUI testing, where we import the test data, I want the same for API testing - where I can import a excel from an external source dynamically and give the values to the request. How can I do this? 回答1: As far as I understand your question, you want