Hey Guys, is there a C# equivalent to the VB.Net With statement please?
Thanks
Chubby.
Printable View
Hey Guys, is there a C# equivalent to the VB.Net With statement please?
Thanks
Chubby.
No.Quote:
Originally Posted by Chubby
Take a look at this to know why?
There is no equivalent.
Thanks to all.
Seems crazy, in the days of VB6 I thought it was implied that regardless of readability, using a With block was faster that accessing the pointer each time you wanted to set a property etc....
Amusing, the way that the designers "think" a With block is a curse, I for one find it easier readability wise...
Thanks Again.
Chubby.
Take a look at this thread.
Yes, but you can compare VB 6 to VB.NET or C#. :)Quote:
Originally Posted by Chubby
Very good Thread.Quote:
Originally Posted by Hack
Thanks for that.
Chubby.
There's a way to simulate the same sort of problems that 'With' produces:
http://www.tangiblesoftwaresolutions...0VB%20With.htm