Brackets around variables

  • Thread starter Thread starter Lou
  • Start date Start date
L

Lou

I see brackets in variable names in the help files code examples. What do
they mean
example [text}
Delegate Sub SetTextCallback(ByVal [text] As String)
 
It allows to use a reserved keyword as an identifier.

For example :
Public Sub [Then](ByVal [String] As String)

End Sub

IMO not needed for Text that is unlikely a reserved keyword...
 
Thanks. I looked every where. I was amazed it wasn't in the on-line help.


Patrice said:
It allows to use a reserved keyword as an identifier.

For example :
Public Sub [Then](ByVal [String] As String)

End Sub

IMO not needed for Text that is unlikely a reserved keyword...
--


Lou said:
I see brackets in variable names in the help files code examples. What do
they mean
example [text}
Delegate Sub SetTextCallback(ByVal [text] As String)
 
Why would you want to do that?

-New to vb... just wondering if there would ever be a practical reason for
it instead of just calling
your sub " Then_A" or something else.

Why go thru the hassle or it later on down the road ?
I cant think of an instance where the function name matterd so much ?

Miro


Lou said:
Thanks. I looked every where. I was amazed it wasn't in the on-line help.


Patrice said:
It allows to use a reserved keyword as an identifier.

For example :
Public Sub [Then](ByVal [String] As String)

End Sub

IMO not needed for Text that is unlikely a reserved keyword...
--


Lou said:
I see brackets in variable names in the help files code examples. What do
they mean
example [text}
Delegate Sub SetTextCallback(ByVal [text] As String)
 
Back
Top