Hello There, I'm sort of a newbie to VBA. I'm trying to set up a macro thatv will enable me to export a whole workbook each tilme i change the parameters;
For some time, the code was working fine but nom it's giving me Error 6, which i dont know the cause.
I would very much appreciate the help.
Here's the code.
For some time, the code was working fine but nom it's giving me Error 6, which i dont know the cause.
I would very much appreciate the help.
Here's the code.
VBA Code:
Sub MySave23()
Dim ws As Worksheet
' Look through each sheet and hard-code formulas
For Each ws In ActiveWorkbook.Worksheets
ws.Activate
ActiveSheet.UsedRange.Value = ActiveSheet.UsedRange.Value
Next ws
' Save workbook
Application.DisplayAlerts = False
ActiveWorkbook.SaveAs ActiveWorkbook.Path & "\Filename_" & Format(Date, "dd-mmm-yy") & ".xlsb", xlExcel12
Application.DisplayAlerts = True
End Sub