C# over VB

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi,

Can anyone list advantages/disadvantages of C# compared to Visual Basic (not
VB.NET, just regular VB)?

Please advice, thanks!
-CL
 
Hi Paul,

On C# side:
1. (and most important) It supports true OO programing
2. The best language grammar, based on C++ (& Java)
3. The source code is separated from the resources.
4. Native support for most of programming technology
(XML, sockets, HTTP, DB,...)
5. Operator overloading.

.... and many many more

Cheers!

Marcin
 
Marcin said:
Hi Paul,

On C# side:
1. (and most important) It supports true OO programing
2. The best language grammar, based on C++ (& Java)
3. The source code is separated from the resources.
4. Native support for most of programming technology
(XML, sockets, HTTP, DB,...)
5. Operator overloading.

... and many many more

Some of the credit goes to the .NET framework, not C#. I don't think there's
choice between C# and VB6. There's only a choice between .NET (C#, VB.NET,
....) and VB6.

Cheers,
 
Hi,

Probably you're right!
But i've got not much experience with any other .NET languages
than C# (and VB6 in a past).

Only what i know, that C# has best grammar i've worked.
It is fast in coding (C#), and it offers good performance
in applications (all managed .NET apps).

Cheers!

Marcin
 
Can anyone list advantages/disadvantages of C# compared to Visual Basic
(not
VB.NET, just regular VB)?

Please advice, thanks!
My advice is, if you are new to programming, go for C#.
But if you are a experienced VB programmer and you have limited time, stay
with VB.
 
This is also discussed in
http://www.experts-exchange.com/Programming/Programming_Languages/C_Sharp/Q_20972281.html

One of the most obvious differences is that C# has XML documentation and VB
does not (I think this is going to be rectified in the next version -but
dont count on it)

Essentially it could be argued (and is true to an extent) that if you can
program in one then you can program in the other.

I used to program on and off in VB6 but went for C# because it is cleaner
and a true OO language.
If you have the time then learn C# -you will always be able to use VB for
any quirks it may have but quite honestly I doubt you will want to or need
to.

VB.net programmers will probably champion that language (quite
understandibly) but I have yet to find one good reason to learn it over
C# -except perhaps that there are slightly more jobs for VB.net than C# (Im
in UK) at the moment -but this is changing quickly.

Whatever you decide will not be a mistake, since learning the framework and
real OO is perhaps the biggest obstacle you face.

Br,

Mark.

P.S. Read these articles by this chap, quite interesting.
http://builder.com.com/5100-6373_14-1049896-1-1.html
http://builder.com.com/5100-6373_14-1027686-1-1.html
 
I started out with VB.net and then recieved a copy of C#, What I have found
moving to C# is that there is a better community out there for VB.Net....
Don't get me wrong but the c# Community is getting better, but it still has
a way to go...

But for me I am happy with c# and plan to Stay. To fix the community
problem, I am trying to help as much as I can.
 
Mark,
VB.net programmers will probably champion that language (quite
understandibly) but I have yet to find one good reason to learn it over
C# -except perhaps that there are slightly more jobs for VB.net than C#
(Im in UK) at the moment -but this is changing quickly.

I'm also in the UK, and I would say that C# has already overtaken VB.NET.
I've not written a single line of VB or VB.NET in nearly a year...

Mark
 
was offered a VB.net job having trouble getting a C# one for some unknown
reason ...begining to wish I accepted the VB one ......on second thoughts
.....no I'm not ;-)
 
was offered a VB.net job having trouble getting a C# one for some unknown
reason ...begining to wish I accepted the VB one ......on second thoughts
....no I'm not ;-)

LOL! Are you a contractor, then? I get most of my work from JobServe
 
No m8 used to but prefer to do permie. C# Employers seem to be after 5 years
SOLID VB development background wheras strangely the VB.net employers seem
less concerned. I unfortunately didnt specialise in one area -but in many.
What gets my goat is that in my opinion VB6 really is a completely different
discipline than true OO in C# so that requirement is a little ridiculus.

Anyhow cheers for suggestion. Already use jobserve though,
http://www.planetrecruit.com is quite good too.

Br,

Mark.
 
VB.Net is extensively supported in the VS.Net environment with help like
case-insensitive coding, drop-down menus, easy to use declaration of
event procedures etc while, C# is not so well-supported.

C#, as an OO language, provides for a class member called the class
indexer, while VB.Net does not.

C# also provides for XML documentation while VB.Net does not.

All the above comparisons are made on the v1.1 of the .net framework.

with regards,


J.V.Ravichandran
- http://www.geocities.com/
jvravichandran
- http://www.411asp.net/func/search?
qry=Ravichandran+J.V.&cob=aspnetpro
- http://www.southasianoutlook.com
- http://www.MSDNAA.Net
- http://www.csharphelp.com
- http://www.poetry.com/Publications/
display.asp?ID=P3966388&BN=999&PN=2
- Or, just search on "J.V.Ravichandran"
at http://www.Google.com
 
Ravichandran J.V. said:
VB.Net is extensively supported in the VS.Net environment with help like
case-insensitive coding, drop-down menus, easy to use declaration of
event procedures etc while, C# is not so well-supported.

I'm not sure I'd say that case-insensitive coding is a help, myself -
and Intellisense can correct your case if you like.

There are drop-down menus for types and members in the C# editor, but I
agree there are more in VB.NET.

Personally I don't like the declarative form of event handling, but
that's a whole other discussion.
C#, as an OO language, provides for a class member called the class
indexer, while VB.Net does not.

Yes it does:

Option Strict On

Imports System

Public Class Test

Public Default ReadOnly Property Foo(ByVal i As Integer) As Integer
Get
Foo = i*2
End Get
End Property

End Class

Then from C#:
using System;

class Foo
{
static void Main()
{
Test t = new Test();
Console.WriteLine (t[5]);
}
}

In fact, it's C# which is the "odd" one here - the CLR just knows an
indexer as a property with parameters and the appropriate
DefaultMemberAttribute applied to the type.
C# also provides for XML documentation while VB.Net does not.

True, although there are add-ons you can use to get over that, of
course.
 
Back
Top