03-29-2011, 06:35 PM
Hi team,
I wanted to keep it simple. Here's my code:
And VBScript error throws upon line 11 (w.r.t to qtResourcesTab). Please help me launch the correct Obj Rep and open the driver script in QTP.
I wanted to keep it simple. Here's my code:
Code:
Dim qtApp
Const ForReading = 1, ForWriting = 2
Dim fso, f, result
Set fso = CreateObject("Scripting.FileSystemObject")
Set f = fso.OpenTextFile("C:\Results.txt", ForWriting, True)
Set qtApp = CreateObject("QuickTest.Application")
qtApp.Launch
qtApp.Visible = True
qtApp.Test.Settings.Resources.Libraries.Add(LibraryDirectory&"Generic_function.qfl")
Set qtResourcesTab = qtApp.Test.Settings.Resources
qtTestResourcesTab.ObjectRepositoryPath = "E:\Framework\Object_Repository\AAI_Object_Repository_merged_March24.tsr"
qtp.open "E:\Framework\SampleTest\DriverScript_WithoutDiscount",True,True