Coding in C# for a VB.net developer

Hi

I have been coding in VB.net for a few years now and have been given a possible 4 month project to re-engineer an ASP.net site written in C#.
I need to get up and running in C# as quickly as possible. Could someone please refer me to
a resource or two for getting to know C# for a VB.net developer and maybe a place to convert the code. Thanks
Murray BrownMicrosoft Cloud Azure/Excel Solution DeveloperAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Navneet.Net Full Stack DeveloperCommented:
Hi!

This is good place for your Code Conversion.
http://converter.telerik.com/

Good Cross refrence like
http://www.harding.edu/fmccown/vbnet_csharp_comparison.html

Thanks!
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
CodeCruiserCommented:
I have been using VB.NET for 8 years. I am a VB MVP. But since September, I am coding C# in my new job. Its just a matter of getting used to those curly braces and semicolons.
0
käµfm³d 👽Commented:
I agree with CodeCruiser. I started with VB, but I now work in C# (and write VB only on EE). If you are familiar with .NET classes, then your primary concern is focusing on C#-specific syntax (which is C-style a.k.a. Java-style). You also have to be mindful that C# is case-sensitive (where VB is not), and a few other subtleties like the difference in adding dynamic event handlers, implicit conversions/casts, and no difference in Sub and Function (a "Sub" in C# is a function that "returns" void), to name a few.
0
PMI ACP® Project Management

Prepare for the PMI Agile Certified Practitioner (PMI-ACP)® exam, which formally recognizes your knowledge of agile principles and your skill with agile techniques.

käµfm³d 👽Commented:
implicit conversions/casts
I should have expanded that a bit. VB, if you let it, allows a good bit of implicit conversion. In C#, you have to explicitly cast unless you override an implicit operator on your class (you can't override the operator for Framework classes).
0
CimperialiCommented:
my two cents:
Do not forget that in VB you say "give me a zero to 4 array" when you want a 5 cells array, while in c# you say "give me 5 cells array" - that is
string[5] myArray
is a 0 to 4 array...
 
Another handly stuff in vb is the Handles keyword you can put on routines to manage events around. in c# you must get accustomed to the += delegate_for_event_handlers sintax

But as others said, the common language runtime and base classes are still there. By the way, if you're in difficoult, remember you could always have vb.net dll invoked from c# (and vice versa, of course). That is: if you have a hard time, you could wrap some useful code in a dll and add a reference to it inside your c# stuff...
0
MattiCommented:
Hi!

http://www.icsharpcode.net/opensource/sd/
In This tool you can select Your #C code to be converted and saved as .NET code

Matti
0
Murray BrownMicrosoft Cloud Azure/Excel Solution DeveloperAuthor Commented:
I appeciate the help. Pity I can't award more points to you each
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
C#

From novice to tech pro — start learning today.