I got an error "The"flightres" Dialog was not found in the
Object Repository. Check the OR to confirm that the object
exists or to find the correct name for the object." while
running the following script

Set flightres=description.Create()
flightres("text").value="Login"
flightres("Class Name").value="Dialog"

Set agent = description.Create()
agent("nativeclass").value="WinEdit"
agent("attachedtext").value="Agent Name:"

Set pwd = description.Create()
pwd("nativeclass").value="WinEdit"
pwd("attachedtext").value="Password"

Set button = description.Create()
button("nativeclass").value="WinButton"
button("Text").value="OK"

Dialog("flightres").WinEdit("agent").Set "test"
Dialog("flightres").WinEdit("pwd").Set "mercury"
Dialog("flightres").WinButton("button").Click

Please let me know if i made any mistake in the above script...?

Answers were Sorted based on User's Feedback



I got an error "The"flightres" Dialog was not found in the Object Repository. Check ..

Answer / raj

Don't put object name in qoutes.

write like
Dialog(flightres).WinEdit(agent).Set "test"
Dialog(flightres).WinEdit(pwd).Set "mercury"
Dialog(flightres).WinButton("button").Click

If you put object name in qoute then qtp try to find that
object in OR.

Is This Answer Correct ?    2 Yes 0 No

I got an error "The"flightres" Dialog was not found in the Object Repository. Check ..

Answer / radhika

Hi the description for the above object is incorrect

Flightres object
flightres("text").value="Login"
flightres("Class Name").value="Dialog"
Instead of Class Name you should put it as "micclass"

Is This Answer Correct ?    1 Yes 1 No

I got an error "The"flightres" Dialog was not found in the Object Repository. Check ..

Answer / narandra

Dialog("flightres").Activate
Dialog("flightres").winedit("Agent Name").set "test"
Dialog("flightres").winedit("Password").set "merury"
Dialog("flightres").winbutton("ok").Click

Is This Answer Correct ?    0 Yes 0 No

I got an error "The"flightres" Dialog was not found in the Object Repository. Check ..

Answer / roli mohanty

do not put theobject in quotes if u put on quotes qtp
sercch the object in OR for which the error come
Dialog(flighters).WinEdit(agent).set"test"
Dialog(flighters).WinEdit(pwd).set"mercury"
Dialog(fighters).WinButton(button).click

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More QTP Interview Questions

what are build and version plz explain why nomber changes in build and version?

3 Answers  


if we can find the status of script in qtp that either it's pass or fail then why we need to put this status on different excel file or log file in hybrid framework .please let me know asap thanks

1 Answers   iCreate,


What is the difference between QTP 8.2 and QTP 9.2

1 Answers  


How will u declare a variable to access multiple actions? a)Dim b)Global c)Public d)Private

1 Answers  


how to write the descriptive programming in QTP for remove the object value and substitute, with a variable then call the validation from excel

0 Answers  






why we use environment variables

5 Answers  


Plz write the code, function will take the parameter as month number, i.e., numerical value, but it returns the last day of the month in string (weekday). example: input: function parameter: 3(march) output: thursday

1 Answers  


what is the general issues faced while using automation tool Qtp9.0

1 Answers   TCS,


what about f2&f6 function keys

1 Answers  


What is LoadRunner?

1 Answers   Crea,


What is quicktest professional window?

0 Answers  


what is the difference between Table checkpoint and Database checkpoint in QTP

2 Answers   Ordain Solutions,


Categories