Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Capturing the WinEdit text in QTP10.0 on Win7
#1
Solved: 11 Years, 4 Months ago
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
Reply
#2
Solved: 11 Years, 4 Months ago
Hi Joe,

Try output checkpoints or GetROProperty.
Reply
#3
Solved: 11 Years, 4 Months ago
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()
Reply
#4
Solved: 11 Years, 4 Months ago
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.

Reply
#5
Solved: 11 Years, 4 Months ago
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.
Reply
#6
Solved: 11 Years, 4 Months ago
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.

Reply
#7
Solved: 11 Years, 4 Months ago
Please find attached the screenshot... The WinEdit object is in the object repository...

Please advise.


Attached Files Image(s)
   
Reply
#8
Solved: 11 Years, 4 Months ago
try below code and let me know the results

Code:
Window("Flight Reservation").WinEdit("Flight No:").highlight

Reply
#9
Solved: 11 Years, 4 Months ago
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".
Reply
#10
Solved: 11 Years, 4 Months ago
Hi Joe

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

Regards,
Prasad
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  Need to Validate Text filed is blank after clicking on the Text box balak89 3 4,905 09-13-2015, 12:06 AM
Last Post: ADITI1992
  Capturing a value in a webtable EK21 4 4,386 08-21-2015, 01:08 AM
Last Post: EK21
  Need help in capturing the Calculator result using QTP 11 vishruth143 0 2,110 01-20-2015, 11:08 AM
Last Post: vishruth143
  QTP 11 and IE9 64bit on Win7&SP1 64bit, QTP does not recognize objects in website jpalos 4 8,721 08-27-2014, 10:11 AM
Last Post: vinod123
  How to mask the particular read only mode fields while capturing screenshot in QTP kalaivanan123 2 3,531 03-18-2014, 11:31 AM
Last Post: basanth27

Forum Jump:


Users browsing this thread: 1 Guest(s)