Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Disabled but Dynamic WinEdit Box
#1
Solved: 11 Years, 4 Months ago
Hi Friends.

In QTP Windows testing i am trying with it's Flights Application.

a. Login.
b. Create New Order.
c. Click Insert Order Button.
d. After Few seconds, there is a disabled text box that displays the order number, i want to capture that order number into the global data sheet. however i am not able to do so. i tried to create a function and tried to display the value of order number generated in msgbox. see code below.

Question 1: Can you help me in using order number to be capture as an output value of my action into the global sheet of the parent action.

Question 2: Please let me know what is wrong with this code below?


Code:
Window("Flight Reservation").WinButton("Insert Order").Click
wait(10)
Sub GetOrderNumber()
     value = Window("Flight Reservation").WinEdit("Order No:").GetROProperty(text)
     msgbox(value)
End Sub

Regards
Nikhil
Reply
#2
Solved: 11 Years, 4 Months ago
Hi,

Code:
Window("Flight Reservation").WinButton("Insert Order").Click
wait(10)
Sub GetOrderNumber()
   value = Window("Flight Reservation").WinEdit("Order No:").GetROProperty("Text")
      Datatable.value("OrderNumber",dtGlobalSheet")=value
End Sub

Call GetOrderNumber()
msgbox  Datatable("OrderNumber",dtGlobalSheet")

Note: ordernumer generated as an Output will be assigned to RunTime Datatable's GlobalSheet in Test Results
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  object disabled eliass 1 1,712 05-30-2017, 02:28 AM
Last Post: Vichu M J
  How to set a value if webEdit control is disabled? rohit.kum.02@gmail.com 1 3,538 12-30-2015, 12:25 PM
Last Post: vinod123
  Smart identification is disabled for PSFrame object guruprasadnagarali 3 5,218 08-18-2012, 11:25 PM
Last Post: savitripatil
  Need information on disabled text box. sambu240 3 4,016 08-18-2012, 10:03 AM
Last Post: ravi.gajul
  Default value in Edit Box when Check Box is checked nacchio 2 5,093 07-18-2012, 12:21 PM
Last Post: sree.85

Forum Jump:


Users browsing this thread: 2 Guest(s)