Enable Developer Tab

To display the Developer tab, click on File in the menu bar and select Options from the drop down menu.

When the Excel Options window appears, click on the Customize Ribbon option on the left. Click on the Developer checkbox under the list of Main Tabs on the right. Then click on the OK button.

Select the Developer tab from the toolbar at the top of the screen. Then click on the Visual Basic option in the Code group.

Now the Microsoft Visual Basic for Applications editor should appear and you can view your VBA code.