Dim X as New Y vs. Dim X as Y = New Y()

前端 未结 3 1634
借酒劲吻你
借酒劲吻你 2021-01-13 07:54

Duplicate

Whats the difference between declaring as new and as something new something i

Sad that I don\'t know this, but can anyo

3条回答
  •  轻奢々
    轻奢々 (楼主)
    2021-01-13 08:27

    There is no difference. VB.NET offers:

    Dim X As New Y
    

    to be syntactically compatible with the old VB6 declaration syntax.

提交回复
热议问题