Skip to content

Instantly share code, notes, and snippets.

@bervukas
Last active March 1, 2016 11:47
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save bervukas/578bdcf316952af016e3 to your computer and use it in GitHub Desktop.
Save bervukas/578bdcf316952af016e3 to your computer and use it in GitHub Desktop.
Declaring variables on a single line in VBA
Sub CalculatePayroll()
Dim a, b, c, d As Integer '' Incorrect
'' Do this instead:
Dim a As Integer
Dim b As Integer
Dim c As Integer
Dim d As Integer
End Sub
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment