Excel Visual Basic for Applications

FAQ About Excel Visual Basic for Applications

How to create a variable in code panel in Excel?

First we use the Dim command from Dimension to create a variable.

Then we write the name we want to give to the variable.

Then we type As and specify the type of the variable. We write one of the types like string, integer etc. 

The result should look like this;

  • Dim variableName As Integer