Create an Excel file, enter some data and save the file through VB scripting

Dim objexcel
Set objExcel = createobject("Excel.application")
objexcel.Visible = True
objexcel.Workbooks.add
objexcel.Cells(1, 1,1).Value = "Testing"
objexcel.ActiveWorkbook.SaveAs("d:\exceltest.xls")
objexcel.Quit
Create an Excel file, enter some data and save the file through VB scripting Create an Excel file, enter some data and save the file through VB
scripting Reviewed by Animesh Chatterjee on January 15, 2010 Rating: 5

No comments:

Powered by Blogger.