Kiba,
I see three possible problems:
1. "Merge" is an Excel reverved word, so it's not a good choice for a sub
or function name. Change the name from "Merge" to something else.
2. If it's really a module name, you can't "run" a module, so that might be
the problem in that case.
3. A Workbook_BeforeSave event really starts like this:
Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel As
Boolean)
The best way to create this event is to go into the ThisWorkbook module,
choose "Workbook" in the dropdown at the top left and choose the event in
the dropdown at the top right.
hth,
Doug
"Kiba" <(E-Mail Removed)> wrote in message
news:CB85F2EB-9AEA-4E50-94DA-(E-Mail Removed)...
>I get and error when i try to run a module named 'Merge' in the workbook
> section before save.
>
> Sub Workbook_BeforeSave()
>
> Merge
>
> End Sub
>
> How can I make this work?
|