V
Vik
Is there in C# an analog of the With <some obj> - End With construction of
VB?
Thanks.
VB?
Thanks.
Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
Vik said:Is there in C# an analog of the With <some obj> - End With construction of
VB?
Michael C said:Luckily no.
Michael
Vik said:What's wrong with it?
sloan said:I like "this." before member variables.
this.m_name = "the sun";
this.m_dob = "4/4/1900";
Vik said:Thanks Michael.
I supposed the code is faster with the With block
though it's more difficult to debug (because pointing a cursor on an
expression in the With block does not show its value).

keanhee said:Hi,
the with block suppose to run faster it if you want to access the multiple
elements under a class.
The test sample just access one element. so it doesn't really give any
performance benefit.
Want to reply to this thread or ask your own question?
You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.