Micro Focus QTP (UFT) Forums
How Can I use this Syntax? - Printable Version

+- Micro Focus QTP (UFT) Forums (https://www.learnqtp.com/forums)
+-- Forum: Micro Focus UFT (earlier known as QTP) (https://www.learnqtp.com/forums/Forum-Micro-Focus-UFT-earlier-known-as-QTP)
+--- Forum: UFT / QTP Beginners (https://www.learnqtp.com/forums/Forum-UFT-QTP-Beginners)
+--- Thread: How Can I use this Syntax? (/Thread-How-Can-I-use-this-Syntax)



How Can I use this Syntax? - NancyNancy - 02-24-2011

syntax
Code:
Datatable.ImportSheet FileName.vtSrcSheet,VDstSheet



RE: How Can I use this Syntax? - BVVPrasad - 02-24-2011

Hi,

Here is an example to understand the above syntax:
DataTable.ImportSheet "C:\test.xls",1,"Action1"

"c:\test.xls" - Path of the source excel sheet from which you intend to import data from

1 - First data sheet in test.xls file

"Action1" - Name of the data sheet in the QTP data table.

Thanks,
Prasad


RE: How Can I use this Syntax? - NancyNancy - 02-24-2011

Thanks for getting back to me. One more thing to make things clear, I need to import the data from an excel sheet, into the Global sheet, and save it with the TC. However, when I run that script, it goes into the Global sheet, then Gone after the run is finished. Attached is a DOC with screen shots.