simple syntax question

  • Thread starter Thread starter SpaceMarine
  • Start date Start date
S

SpaceMarine

hello,

in the following code:

Dim report As Report = CreateReport()

report!OFFICER_1 = Global.Officer1
report!OFFICER_2 = Global.Officer2
report!UNIT_NUMBER = Global.Officer1.UnitNumber

....can someone please explain what the "!" syntax is in the last three
lines? those arent properties of the Report object itself, so i am
confused.


thanks!
sm
 
SpaceMarine said:
Dim report As Report = CreateReport()

report!OFFICER_1 = Global.Officer1
report!OFFICER_2 = Global.Officer2
report!UNIT_NUMBER = Global.Officer1.UnitNumber

...can someone please explain what the "!" syntax is in the last three
lines? those arent properties of the Report object itself, so i am
confused.

See:

Special Characters in Code
<URL:http://msdn2.microsoft.com/en-us/library/xxda45fy.aspx>
-> "Exclamation Point (!) Operator"
 
SpaceMarine said:
i see. is this a VB.NET only thing?

It's VB.NET shorthand syntax. The '!' operator has already been available
in Classic VB.
 
Back
Top