How to export data present in Datatable to an ".xls"

file?

Answer Posted / sreeprasad

DataTable.Export("Path of the sheet")

or DataTable.ExportSheet("Path of the sheet",Index of the

runtime datatable u want to export")

Is This Answer Correct ?    2 Yes 8 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Is the qtp course will help to create a virtual object?

1715


Is virtual object supported in low level recording mode?

867


What is the architecture of your project? Can any one answer for this question plz........

1588


How many add-ins comes by default with quicktest professional (qtp)?

755


Explain calling sub procedure.

832


What is a data driven test in qtp?

783


What is difference between run time object and test object?

761


what is the difference between data driver & data driven and driver script?

2423


What is the use of text output value in quicktest professional?

714


hi all can any body explain how to write the script for finding the mandatory fields which are having [red Astrik sign (*)]

1674


How do you know the location Id of an object if you know its index id?

795


I have two For loop, first For loop does is creates a customer and input the customer info and then the second for loop within the first for loop does the follows which is capture the customer name and verify the with the data within the datatable. The problem I am coming across is that when it goes through the second time creating another customer and then verify the second customer then it creates the following during runtime. I want is to have the customer2 below Customer1 under the Customer_from_Apps. Any help will be greatly appreciate it. Customer Customer_from_Apps Customer_from_Apps1 Customer1 Customer 1 Customer2 Customer2 Window("Customer Desktop").Window("Customer Tracking (Privacy").WinObject("TreeView20WndClass").Click 92,244 runtimevalue = .VbTreeView("vbname:=AppServerTree").GetROProperty("Selectio n") Customer_Val= Datatable.GlobalSheet.AddParameter ("Customer_from_Apps",runtimevalue) row=datatable.getsheet("Global").GetRowCount For x=1 to row datatable.SetCurrentRow(x) Data_Val=Datatable.Value("Customer",dtGlobalSheet) If (trim(Customer_Val)=trim(Data_Val)) Then Reporter.ReportEvent micPass, "Customer validation successful", "Actual Value: " &Data_Val&vbcrlf& "Customer Value: " &Customer_Val else Reporter.ReportEvent micFail, "Cusotmer validation unsuccessful", "Actual Value: " &Data_Val&vbcrlf& "Customer Value: " &Customer_Val End If Next

1574


How does qtp identify gui object?

776


Is any limitation to xml checkpoints?

781


I recorded a Web App with a Oracle backend using QTP 9.5 and for some reason the scripts don't play back> What am I missing at this point. I recorded the same Apps under Sybase and they work great. This is Oracle 10g. Why won't my scripts play back.

1761