Difference between VB.Net and C# “As New WebControl”

后端 未结 4 437
情深已故
情深已故 2021-01-15 06:02

I was refactoring some code, and part of it included moving it from VB.Net to C#.

The old code declared a member like this:

Protected viewMode As New         


        
4条回答
  •  轮回少年
    2021-01-15 06:28

    The default constructor for WebControl (implicit in the VB line) is to use a span. You can call that constructor in c# as well as VB.NET.

提交回复
热议问题