How to Import data from a ".xls" file to Data table

during Runtime.

Answer Posted / sreeprasad

DataTable.Import("path of the file")

DataTable.ImportSheet("filepath","sheetsource","sheetDest")

Sheetsource:index or name of the sheet in the file which u

want to import. index begins vth 1.

SheetDest: index or name of the sheet in the datatable

which u want to replace vth Sheetsource.Index begins vth 1.

ex:

Datatable.importsheet("c:\name.xls",1,"name")

Is This Answer Correct ?    2 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Hi All , How can we decicde for pariticular frame(DataDriven or Keword Driven)in Project? Thanks Balaji

1479


How to analyzing test results using quicktest professional?

732


How to release all resources file from the QTP?

1139


Hi, how can we check or avoid the memory leakage in QTP9.2?

1765


What is the use of "New Property" in "Add properties" of testobject properties in object repository. How can i use "New properties" while writing scripts if i have assign some values to the testobject properties Can anyone help me? plz

1566






What are the views available in quicktest professional?

647


What is the difference between byref and byval in qtp?

675


There is an excel file of 1 to 100 sheets how you will iterate through it?

627


Whether qtp 9.0 supports Test director8.0

2226


Explain the types of object repository?

641


Hi any body pls help me for QTP 11.0 software free demo version. i have to practice. Kindly send the link.or where i have to download.

1793


What is file database?

1771


Hi How to retrieve data from web element line by line?

1659


QTP 10.0 is not identifying web objects for IE 8.it is identifying like winObject.I installed HP patch QTPWEB_00037.Still getting issue

5673


What are the different attribute used with regular expression?

614