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.

 All Forums
 SQL Server 2000 Forums
 Import/Export (DTS) and Replication (2000)
 Export to New Excel File and Macro

Author  Topic 

Keveroo83
Starting Member

1 Post

Posted - 2008-02-04 : 17:46:56
Hey guys,

I am trying to set up a service that will be able to automatically export data based on a query I write to a new excel file and then run a short macro for formatting. Once the file is created, I want to have it automatically emailed to various recipients.

I believe I have several pieces that I need to get it to work, but I can't seem to get them to work together the way I want to.

I am able to successfully create a DTS package that exports data to an Excel file, but if I run the DTS package a second time, it errors out because it can't overwrite the previous file.

When I try to run the macro on the first run through the DTS package, it errors out because it can't find the macro even though I've loaded it through an add on.

I have loaded the XPSMTP component for emailing, but I haven't gotten far enough with the other pieces to start working with this yet.

Do any of you have suggestions for how to handle this operation or can you provide me with examples of a similar operation?

Thanks,
Kevin
   

- Advertisement -