VBA: CopyWorkbookWithoutFormulas

Created by Damien Zwillinger, Modified on Thu, 5 Oct, 2023 at 5:56 PM by Gabriel Michaud

Applies to:

  • Velixo Classic
  • Velixo NX (when used with Excel on Desktop)

Important: Visual Basic for Applications macros are not supported by Excel Online.


Copies the active workbook without Velixo's formulas to a specific location on the disk.


See Introduction to Velixo's VBA functions for general usage information.



objVelixo.CopyWorkbookWithoutFormulas TargetPath

objVelixo - a variable that represents an instance of the Velixo VBA functions class.








A String value that provides the full destination file path, including extension. 


If the file already exists it will be overwritten.


Supported extensions: ".xlsx", ".xls", ".xlsm", ".xlsb".


Newly created workbook becomes the active workbook.


If Application.DisplayAlerts is set to False, any message boxes will be suppressed. This is especially useful for a fully unattended automation. Once completed, set DisplayAlerts back to True


Pro tip: Macros can be removed from an Excel Macro-Enabled Workbook file (*.xlsm) by providing a TargetPath for a standard Excel Workbook file (*.xlsx).



Dim velixoObj As Velixo_Reports.VBA
Set velixoObj = CreateObject("Velixo.Reports.Vba")

Application.DisplayAlerts = False

velixoObj.CopyWorkbookWithoutFormulas "C:\The\Desired\Path\FileName.xlsx"

Application.ActiveWorkbook.Close SaveChanges:=False

Application.DisplayAlerts = True

Was this article helpful?

That’s Great!

Thank you for your feedback

Sorry! We couldn't be helpful

Thank you for your feedback

Let us know how can we improve this article!

Select at least one of the reasons
CAPTCHA verification is required.

Feedback sent

We appreciate your effort and will try to fix the article