Reputation: 31
Situation: every 2 weeks we need to download 3 Excel workbooks from a website, each time we need to open these 3 files and delete always the same rows, for example in the first downloaded Excel workbook we need to delete the first 4 rows, in the 2nd Excel workbook we need to delete the first 4 rows and then the 6th row, etc... What would be the best way to approach this? Could this eventually be done from within a DOS batch file or a VB script? Or is something more advanced required? Any help is most appreciated.
Upvotes: 0
Views: 560
Reputation: 7836
A VB script could do it. I'd suggest you create a new workbook, and record a macro into that workbook which does what you want. Then you could put a button onto your new workbook to run the macro. As long as all workbook filenames each time and rows to be delated are identical, that should work. Bear in mind, though, that I sometimes find that it's necessary to clean up the macros that excel records, in order to make them more robust.
Upvotes: 1