In my frame work i have an VBS file by name initialization file, which does initial QTP settings during runtime.
This Frame work was developed for QTP 8.2.
The code inside initialization file is
Public Function InitializePath(Libr_Path,Data_Path,Scripts_Path,te st_dir)
Dim App 'As Application
Set App = CreateObject("QuickTest.Application")
App.Visible = True
'App.Test.Settings.Resources.ObjectRepositoryPath = "..\..\ObjectRepository\Mphasis_RK_Search.tsr"
App.Associate Repositories.RepositoriesPath = "..\..\ObjectRepository\Mphasis_RK_Search.tsr"
App.Test.Settings.Run.ObjectSyncTimeOut = 50000
App.Test.Settings.Run.DisableSmartIdentification = True
App.Options.Run.RunMode = "Normal"
App.Options.Run.ViewResults = False
App.Options.Run.CaptureForTestResults = "Always"
But when i try to Open it in QTP 9.0 it throws an error because the Location of Object repository has been changed in QTP 9.0.
Before in 8.2 i used to load the Obj Repository file by below code
"App.Test.Settings.Resources.ObjectRepositoryP ath "= "..\..\ObjectRepository\Mphasis_RK_Search.tsr"
Now in QTP 9.0
if i try to do like,
App.Resources.Associate Repositories.RepositoriesPath = "..\..\ObjectRepository\Mphasis_RK_Search.tsr"
if i try to get the path by pathfinder.locate during runtime, no path is displayed
Will any one of u please help me out to overcome this issue.
I suggest you go through the help and the manuals as from version 6 through to 8.2 there have been slight changes to the construct of what you are trying to do. So what works in one version will not necessarily work in the newer version.
ObjectRepositoryPath is no longer supported. Look at QTP automation object Model Reference under Resources Object for additional information.
This property is no longer supported. Use the methods and properties of the ObjectRepositories collection instead.