I have written a macro to allow a user to enter a customised footer, this is stored in ThisWorkbook in a template and is set to run on opening the template. I want the macro to become inactive after the workbook has been saved as an .Xls file.
I have tried the code:
If Application.ActiveWorkbook.FileFormat xlTemplate Then
GoTo lastline
End If
to skip the footer writing code and go to the end of the macro, however it seems that once the template has been opened it ceases to have fileformat xlTemplate, so this approach is not working. Can anyone help?