Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

What is the difference (advantages) between VB.NET and C#?

Status
Not open for further replies.

RedLion

Programmer
Sep 13, 2000
342
NL
Hello,

Probably you would say by reading this thread not again…
But I’ve looked everywhere on MSDN and so on but the only thing I can find is that .Net is so great and a lot of advantages against VB, but nothing about the differences between C# and VB.NET

Question:
What is the difference (advantages) between VB.NET and C#?

A few points:
1. Is there a difference in handling strings?
2. Is one of the languages higher than the other?

And more...

Thanks for your time,

Charl
 
Oh geez, NOT AGAIN!
;)

just kidding Red. I just came back from a VS.NET launch event, and the feeling I came away with was that other than syntax, there is virtually no difference between teh two languages (for the most part). I'm sure there are a few minor differences, and the bulk of developers are deffinately adopting C# over vb.net. But from what I gathered, they're pretty close.

Just what i know though.
:)

Jack
 
every languages in .NET have their own advantages and disadvantages :)... eventhough i was using c#, but i was pretty sure that there're almost no differences between vb.net and c#. ask jack what vb.net could do ^-^. well, coz now all the languages stand over the same framework, it means that they share the same libraries :)... so, what are you afraid of??? it's only a matter of syntax ^-^
 
Thanks for the Response!

Reasons why I doubt:

1. When you compare C++ with VFP or VB you'll see that VFP and VB are higher languages then C++ for example VFP and VB handle strings more flexible.

2. I’m currently developing a lot with Visual FoxPro and I’ve developed some apps with Java.

3. A college from me is started with developing in VB.NET.
 
I've found a few new quirks between VB.NET and C#. Nothing super major, but differences nonetheless:

- Property statements in vb.net classes can take a parameter
C# property statements can't
- C# has a built in class generator wizard (sweet!), vb
does not
- the #Region syntax to create expandable/colapseable
areas in code is only available in vb.net
- C# allows for the <summary> tags, which you can output
to an xml document if you ever want a compiled file with
all your code comments in
- C# has an extra type called Pointer Type (as well as
reference type and value type, which vb.net also has)
- vb.net uses Nothing (IsNothing) while C# uses Null(==null)
- C# has wizards for just about every part of class creation
VB.NET doesn't.

Like i said, nothing super major, but a few things to think about.

Jack
 
hi,
tell differences wrt performance!

(hint)
[managed/unmaneged blocks in cpp n c#]
 
Jack,

Not to be a picky so and so but you can use regions in c# I just looked over a co-workers shoulder and saw they were using them. Did you maybe mean the reverse that it is not available in vb.net (I don't know as I have not used vb.net).

habibcs - I have also seen several posts indicating that VB has more built in string functions than I have seen in C#. But usually I have seen someone suggest just using a vb dll to get access to those functions (sorry I can not remember the dll name).

Yes you can use unmanaged code sections within C# code. Issues with doing so include having to be much more careful with cleanup etc, but I guess the benefit is that you control the cleanup (control I am certainly willing to give up for the convenience of knowing the Garbage Collector will do the work for me).

Hope this helps,

Crystal
crystalized_s@yahoo.com

--------------------------------------------------

Experience is one thing you can't get for nothing.

-Oscar Wilde

 
Hey Crys,

kewl, thanks for the heads up!

For some reason when I tried to get the regions to run in C#, it didn't work. But that was a long time ago, and I don't program in the langauge, so maybe teh syntax was different or something?

Anyways, thanks for the post
:)

jack
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top