Tuesday, September 22, 2015

Methods

For example, there is Quit method.

Application.Quit

Sometimes it's difficult to see if it's a method or a parameter because they are written at same place. One way to see if it's a method or not is to see whether the word is a verb or not. If the word is just a noun, it would be a parameter. While if the word is a verb, it would be a method.

Another example is Add method. Here is an example.

Worksheets.Add After:=Worksheets(1)

This is an object "Worksheets". The method is Add. We will see the detail of method later, but this is how method is used.