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

How u perform exception handling in QTp,what is other name for ths

1 Answers   Lehman Brothers,


Hello friends..... On which areas of an application we can not test with QTP

0 Answers   Thatavarti Technologies,


Which environments are supported by hp qtp?

0 Answers  


what is automation(qtp)bug pls giv me one ex?

1 Answers  


How to get Links count in an web application,without descriptive programming?

8 Answers  






Synchronozation types in QTP

11 Answers   Diebold,


is it possible to add sheets to excel at runtime

1 Answers  


Who is the best faculty for QTP in Hyderabad? Is it Mr. G.C.Reddy, some are referring his name?

21 Answers  


vb script for calling one function to the another function

2 Answers  


In Descriptive programing if i use this below code will it work for login window or flight Res Window. Shud i add the properties like attached text=login and text=Agent Name in the object repository and define a new object first. Pls tell me the procedure in clear inorder to execute this script. Dialog("title:=Login").WinEdit("attached text:=Agent Name:").set"agent123" Dialog("title:=Login").WinEdit("attached text:=Password:").set"mercury" Dialog("attached text:=Login").winbutton("text:=OK").click

2 Answers  


How to Identify broken links in QTP

2 Answers   Ness Technologies,


Explain Checking XML....

1 Answers   Crea,


Categories