In Excel 2003 I recorded a macro that sorts event log files saved in csv format. It works on any of my event log csv files. But when I recorded a macro with the same steps within one of the same event log csv files using Excel
2007 it will only work with that original csv file. When I try to run it on another event log csv file it gives me error 9 subscript out of range. When I viewed the code I saw that the macro had recorded the name of the original csv log file.
How do I code the macro so that it will run in any of my event log csv files, as it did in Excel 2003?
↧