Solved

VBScript to delete rows in excel

Posted on 2004-04-27
5
208 Views
Last Modified: 2013-12-25
I need to delete the rows in an excel spreadsheet prior to being reloaded by a DTS transformation.
The needs to run as VB script as part of an activex transformation.
0
Comment
Question by:howertja
  • 2
5 Comments
 
LVL 29

Expert Comment

by:leonstryker
ID: 10931719
What do you have so far?  Why not do this directly from Excel?

Leon
0
 

Author Comment

by:howertja
ID: 10932388
I am selecting records from a SQL database and placing the info in a spreadsheet to mail to a user. If I created a csv file, a new file would be created each time. With a transformation to excel, it appends the sheet. I need to delete the old data and load the new. Loading is not a problem. The transformation handles that. I would just create a csv file and email that but the user is not very knowledgable on how to load it to a spreadsheet.

By the way, this package will run as a scheduled batch process.
0
 
LVL 29

Accepted Solution

by:
leonstryker earned 125 total points
ID: 10932424
CSV is a format recognized natively in Excel.  In fact, if you have Excel installed on your machine and a CSV file is duoble clicked it will be opened in Excel.

Leon
0

Featured Post

IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

Introduction I needed to skip over some file processing within a For...Next loop in some old production code and wished that VB (classic) had a statement that would drop down to the end of the current iteration, bypassing the statements that were c…
Have you ever wanted to restrict the users input in a textbox to numbers, and while doing that make sure that they can't 'cheat' by pasting in non-numeric text? Of course you can do that with code you write yourself but it's tedious and error-prone …
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

746 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

8 Experts available now in Live!

Get 1:1 Help Now