What are the use of square brackets in vba (access)

I am browsing an access database for work now and stumbled upon some kind of confusing code.

Private Sub Form_Current()
  Me.Parent!PF = Me.[Compound Number]
  Me.Parent.start = Me.[Study Start]
    'over and over for different variables
end sub

I am wondering why parentheses are needed for vba (outside arrays) and why does anyone need this code. Thanks

+4
source share
1 answer

Without brackets you will have:

Me.Compound Number

What will be the call of the subroutine called Compoundwith an argument Number.

Square brackets exclude the name of an object that contains a space (or other reserved characters, characters, or words).

+7
source

All Articles