Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
infodemers
Posting Yak Master
183 Posts |
Posted - 2011-06-04 : 23:06:54
|
| Hi,I wish to add a column to cell [A1] in an existing Excel file.Using a stored procedure.Any idea?Thanks! |
|
|
visakh16
Very Important crosS Applying yaK Herder
52326 Posts |
|
|
infodemers
Posting Yak Master
183 Posts |
Posted - 2011-06-07 : 13:27:12
|
| Hi visakh16,I got it to work using the ActiveX Script I was already running to copy the excel files to my server, before running the Stored Procedure. Set objexcel = CreateObject("Excel.Application") objexcel.Workbooks.Open sDestinationFile Set objsheet = objexcel.ActiveWorkbook.Worksheets(1) objsheet.Columns("A").EntireColumn.Insert objExcel.ActiveWorkbook.Save objExcel.ActiveWorkbook.Close objExcel.Quit Set objexcel = Nothing Set objsheet = Nothing |
 |
|
|
|
|
|