Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
run problem about O.R.
#1
Solved: 11 Years, 4 Months ago
I have not yet understood the basic functioning of QTP: i have registered the opening of a website, and it runs correctly.
Then i have copied & pasted the same code in another blank sheet, and i have ran it: it doesn't function, with the error:
The "Browser"object was not found in the Object Repository. Check the Object Repository to confirm that the object exists or to find the correct name for the object.

The code is:
Code:
Dim link2
link2="http://www.google.it"
SystemUtil.Run "C:\Programmi\Internet Explorer\iexplore.exe","","C:\Documents and Settings\zzsvo02","open"
Browser("Browser").Page("Page").Sync
Browser("Browser").Navigate link2

if i use the record key and i open google website, the code written in the expert view is the same... but it functions...
How does OR function? or where i can find a process explanation? (not only the single detail, but an overview to understand the functioning)

thanks for any help,
ste
Reply
#2
Solved: 11 Years, 4 Months ago
Hi
you can never copy or paste the script as new script.
You should record the script so that all ojects are collected in object repository.
In the new script which you copied and pasted u will not find any object.
Just check the object repository of the new script which you copied and pasted,u find no object there since u never recorded itSmile
Reply
#3
Solved: 11 Years, 4 Months ago
but is there a method to write code in expert view able to function without a pre-existent record? With some setting of objects or similar? or, indipendently of the possibility, it's a bad idea?
thx,
ste
Reply
#4
Solved: 11 Years, 4 Months ago
Dear Stevol,
When ever you record any application in QTP it is going to store all the objects in Object Repository what ever the objects you are used.

For example in gmail you entered username and passowrd and then you clicked on signin so it is going to record all these object and store in the object Repository.

So that you can use these object and you can do many things with this.

If you do not want to use Object Repository then you need to go to Desriptive Programming.Please follow the below link to know more about that.

http://www.slideshare.net/yassa/qtp-desc...rogramming

Hope it helps...
Regards
Sridhar
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  HP Run Results Viewer Reporting Problem Arjun279 1 7,082 12-04-2010, 01:30 AM
Last Post: Avital

Forum Jump:


Users browsing this thread: 1 Guest(s)