Read and Load global datatable from Resources tab folder from QC to QTP

564 views
Skip to first unread message

Dineshkumar Rajendran

unread,
Jul 9, 2012, 5:17:41 PM7/9/12
to QTP eLearn Team
Hi Friends,
 
Does anyone send me the code for read and load global datatable from Resources tab folder from QC to QTP?
 
I tried the below code, but giving error as 'path does not exist"
 
Quote:
 
XLdatafile = PathFinder.Locate("[Quality Center\Resource] Resources\PSHTestData\PSHSampleData\PSHDatasheet.xls")
'Datatable.Import (XLdatafile)
 
Unqutoe
 
Thanks,
Dinesh

Jitendra.S

unread,
Jul 9, 2012, 5:56:34 PM7/9/12
to qtp-ele...@googlegroups.com

Make sure that located same  path in Test setting>> Resource >>Data table>>Other source 

Dinesh

unread,
Jul 9, 2012, 7:09:08 PM7/9/12
to Jitendra.S, qtp-ele...@googlegroups.com
Hi Jitendra, 

I tried, when I run the test after resource folder path set in test settings; file loaded to the test In the run time before actual test started. This is really a good solution if we depend on one test data sheet from QC resource tab. But in my project I have more than one test data files in different folders in QC resources tab. I need to refer the different data sheets at run time.

Thanks in advance

Dinesh

Sent from my iPhone

Jitendra.S

unread,
Jul 9, 2012, 7:54:03 PM7/9/12
to qtp-ele...@googlegroups.com
Yes your right ..I was specific to current test/Action only..Yes I know one setting ,Tried long time ..you try this and you can F1 on this so get full description about this..
I am assuming your using Relative path so ..try this    "Tool>>Option>>Folder>>select  Remind me to relative path..." and pls let me know it will work for you or not..



Reply all
Reply to author
Forward
0 new messages