Micro Focus QTP (UFT) Forums

Full Version: Capturing the WinEdit text in QTP10.0 on Win7
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2
Hi,

I am using QTP 10.0 on Windows 7...

I am having difficulty in capturing the text in the "WinEdit" object.
Like the text in the sample application: Flight in QTP
I need to capture the "Flight No.", "Departure Time:"... etc... all of these are non-editable...

Thanks in Advance...
Joe
Hi Joe,

Try output checkpoints or GetROProperty.
Thank u for the reply... but i m facing the same problem...

I have tried the following code but i m unable to pickup the text
Code:
Code:
Window("Flight Reservation").WinEdit("Flight No:").GetROProperty()
GetROProperty needs the Property to retrieve from the object, you should pass the property like text, value etc to get the value from your winedit object. Window("Flight Reservation").WinEdit("Flight No:").GetROProperty("text") should work here.
Hi Saket,
I am trying to capture the text in the WinEdit object and copy it to the Excel sheet... I have copied the WinComboBox object but i am facing a problem with WiEdit...

I am facing the following error:
"Cannot identify the object "Flight No:" (of class WinEdit). Verify that this object's properties match an object currently displayed in your application.

Line (38):
Code:
"objWorkbook.Sheets("Sheet1").Cells(i,4).Value = Window("Flight Reservation").WinEdit("Flight No:").GetROProperty("text")".
Tip: If the objects in your application have changed, the Maintenance Run Mode can
help you identify and update your steps and/or the objects in your repository."

Please advise.
as the error states - Check if the object is in your repository, try to highlight the object. if not then updating your object should solve the issue.
Please find attached the screenshot... The WinEdit object is in the object repository...

Please advise.
try below code and let me know the results

Code:
Window("Flight Reservation").WinEdit("Flight No:").highlight
the following error occured on trying the above code:

General run error.

Line (38):
Code:
"objWorkbook.Sheets("Sheet1").Cells(i,4).Value = Window("Flight Reservation").WinEdit("Flight No:").highlight".
Hi Joe

Can you remove the object present in the object repository, leart it again and try running the code.

Regards,
Prasad
Pages: 1 2