I made a quick macro to save an excel sheet to a certain location and with a certain name depending on the cell value. The macro is executed when I push a custom button on the quick access tool bar. It worked great for a while and now it is not working at all. It will close the document, but not save it. Any ideas what I could be missing?
Sub ECN_SAVE()
THISFILE = Range("R3").Value
FILETHIS = Range("Q6").Value
ActiveWorkbook.SaveAs Filename:="I:\ECN\New Ecn's\" & FILETHIS & "_" & THISFILE
ActiveWorkbook.Close
End Sub
A little more background. I has this associated with an excel sheet that I saved and put in the excel start up folder. I tried changing it so the macro would be there with no docuements open. It worked twice and then stopped working. This should be able to run without a certain document open, right?
Sub ECN_SAVE()
THISFILE = Range("R3").Value
FILETHIS = Range("Q6").Value
ActiveWorkbook.SaveAs Filename:="I:\ECN\New Ecn's\" & FILETHIS & "_" & THISFILE
ActiveWorkbook.Close
End Sub
A little more background. I has this associated with an excel sheet that I saved and put in the excel start up folder. I tried changing it so the macro would be there with no docuements open. It worked twice and then stopped working. This should be able to run without a certain document open, right?