VBA - Updating a procedure or function

June 2017



Managing a workbook using only the standard functions of the spreadsheet may be problematic. To manage your procedures and custom functions, you can use the Visual Basic Editor: Go to Tools > Macro > Visual Basic Editor or press Alt + F11 simultaneously.

The following window "Project - VBAProject" shall be displayed, if it is not present, go to View > Project Explorer or simply press Alt + R.
In this window, you will see your file and you can expand its tree as explained below:
  • the "Microsoft Excel Objects" folder including:
    • one a line for each worksheet - for specific procedures of each sheet.
    • the "ThisWorkbook" line, for procedures workbook.
  • the "Sheet" folder, if you have created forms, with the list of forms.
  • the "Modules" folder, for one line created for each module.

If you used the macro recorder to record your procedure, you will find it in a module (with the name you gave it).
  • If you want to introduce a procedure from an online source or forum, double click on the appropriate line and paste the it.
  • To create a module or a procedure, use the Insert menu.
  • A custom function must be created in a standard Module in order to be called from a sheet.

Related


Published by deri58. Latest update on June 17, 2013 at 04:37 AM by deri58.
This document, titled "VBA - Updating a procedure or function," is available under the Creative Commons license. Any copy, reuse, or modification of the content should be sufficiently credited to CCM (ccm.net).