VB.NET or C# wich one should I choose & why? 
Author Message
 VB.NET or C# wich one should I choose & why?

I

I'd like to have some help on this: opinions; links to docs discussing this
and anything related. What can I do in C# that I can't in VB.NET; how
coherent are them etc...

THNKS



Tue, 02 Mar 2004 17:56:22 GMT  
 VB.NET or C# wich one should I choose & why?
The 'only' differences are:

C# allows unsafe code (pointers)
C# allows operator overloading

As for advice:

C# is very much like C++ and Java
VB.NET is very unlike VB6

I'd go for C# when fammiliar with C++\Java.
I'd choose VB.NET if the boss wants me to.

To me this means that I do both. Don't think that VB6 experience will help
you to quickly and fully understand VB.NET; you will have to start all over
again.

Good luck!

BTW: All .NET languages use the same .NET platform/base classes so you will
only have to learn them once!

Erno



Tue, 02 Mar 2004 18:11:00 GMT  
 VB.NET or C# wich one should I choose & why?
Check out this link, which leads you to Dan Appleman's E-book "Visual
Basic.NET or C#? Which to Choose?"

--
Carsten Thomsen
Database Programming with VB.NET
(http://www.apress.com/catalog/book/1893115291/)


Quote:
> I

> I'd like to have some help on this: opinions; links to docs discussing
this
> and anything related. What can I do in C# that I can't in VB.NET; how
> coherent are them etc...

> THNKS



Tue, 02 Mar 2004 18:44:59 GMT  
 VB.NET or C# wich one should I choose & why?
Choose which ever one you like. If you ever need C# functionality from VB,
well, that's very easy to do.


Quote:
> I

> I'd like to have some help on this: opinions; links to docs discussing
this
> and anything related. What can I do in C# that I can't in VB.NET; how
> coherent are them etc...

> THNKS



Tue, 02 Mar 2004 22:56:05 GMT  
 VB.NET or C# wich one should I choose & why?

Quote:
> Choose which ever one you like. If you ever need C# functionality from VB,
> well, that's very easy to do.

Very true. Except for the ability to write unmanaged code and operator
overloading as well as a few other trivial differences.

This is something though, that I don't think has been stated enough. Not
many people realize that you can use the C# methods directly from VB.NET
(and vice versa) just by importing the C# classes.
--
Regards,
Cal



Tue, 02 Mar 2004 23:01:38 GMT  
 VB.NET or C# wich one should I choose & why?


Quote:
> > Choose which ever one you like. If you ever need C# functionality from
VB,
> > well, that's very easy to do.

> Very true. Except for the ability to write unmanaged code

I'm sure everyone who's been here for a while knows this, but...

'unsafe' <> 'unmanaged'
'unsafe' code uses pointers directly. You can do this in C#, but not in
vb.NET.
'unmanaged' code doesn't use the .NET CLR. Neither C# nor vb.NET can do
this.

--
Dave Rothgery



Tue, 02 Mar 2004 23:14:14 GMT  
 VB.NET or C# wich one should I choose & why?

Quote:
> 'unsafe' <> 'unmanaged'
> 'unsafe' code uses pointers directly. You can do this in C#, but not in
> vb.NET.
> 'unmanaged' code doesn't use the .NET CLR. Neither C# nor vb.NET can do
> this.

DUH! My bad... Should have read my post before hitting send. :-)

Sorry for the misinformation! :(

To even clarify further C++.NET is the only MS language under .NET to allow
for "unmanaged" code.

--
Regards,
Cal



Tue, 02 Mar 2004 23:19:56 GMT  
 VB.NET or C# wich one should I choose & why?
Don't be so sure about knowing the "only" differences.  They are different
languages, and these are both very complex languages. For example:

* VB.NET support a more (arguably) powerful Select...Case instead of C#'s
Switch...case.
* C# support XML documentation similar to JavaDoc. IIRC VB.NET does not
support this.
* C# is case sensitive. This is arguably a good thing, but many from the VB
camp believe otherwise.
* C# supports operator overloading.  Although some scoff at the real
beneftis of this, many also commend it's ability to make tasks like event
handling easier to read and understand.
* VB.NET supports typeless "scripting". Meaning, it doesn't have to be
strongly typed. Some call this a feature, others call it a caviat.

C# generally has a smaller code base, and performs a bit faster (up to 5%)
than VB.NET.  This point should NOT be considered when choosing between
languages, rather, it should shatter the myth that all languages that use
the CLR are the "same".  Languages that use the CLR are definatly different
languages beyond syntax. The benefit comes when you can compile a class in
one language, and inherit it in another.

You really need to find what language makes the most sense to you.  I
strongly believe that this goes well beyond comfort of syntax. Look at the
potential job market (will there be more VB.NET jobs or C# jobs?), look at
each languages specific features, and look at the philosphy behind the
design of each language, so that you can gauge the future of it.

Quote:

> The 'only' differences are:

> C# allows unsafe code (pointers)
> C# allows operator overloading

> As for advice:

> C# is very much like C++ and Java
> VB.NET is very unlike VB6

> I'd go for C# when fammiliar with C++\Java.
> I'd choose VB.NET if the boss wants me to.

> To me this means that I do both. Don't think that VB6 experience will help
> you to quickly and fully understand VB.NET; you will have to start all ove
r
> again.

> Good luck!

> BTW: All .NET languages use the same .NET platform/base classes so you
will
> only have to learn them once!

> Erno



Wed, 03 Mar 2004 00:43:11 GMT  
 VB.NET or C# wich one should I choose & why?
The future may bring more differences between the two languages than there
currently are. The following link points to an article on ZDNet that talks
about Microsoft splitting the C# & VB.NET roadmaps (includes quotes from
Brian Harry, Microsoft CLR product unit manager). I realize that this is
nothing "official" from MS, but I would consider ZDNet a pretty reliable
source.

http://news.zdnet.co.uk/story/0,,t269-s2093679,00.html

Anyone have more concrete info about this?
--

Ryan Farley
Lead Application Developer
Customer FX Corporation


I

I'd like to have some help on this: opinions; links to docs discussing this
and anything related. What can I do in C# that I can't in VB.NET; how
coherent are them etc...

THNKS



Wed, 03 Mar 2004 00:47:02 GMT  
 VB.NET or C# wich one should I choose & why?
Don't bother reading that article. The author clearly does not know what he
is talking about.

--
Jonathan Allen


Quote:
> The future may bring more differences between the two languages than there
> currently are. The following link points to an article on ZDNet that talks
> about Microsoft splitting the C# & VB.NET roadmaps (includes quotes from
> Brian Harry, Microsoft CLR product unit manager). I realize that this is
> nothing "official" from MS, but I would consider ZDNet a pretty reliable
> source.

> http://news.zdnet.co.uk/story/0,,t269-s2093679,00.html

> Anyone have more concrete info about this?
> --

> Ryan Farley
> Lead Application Developer
> Customer FX Corporation



Wed, 03 Mar 2004 02:54:49 GMT  
 VB.NET or C# wich one should I choose & why?

Quote:
> > * C# supports operator overloading.  Although some scoff at the real
> beneftis of this, many also commend it's ability to make tasks like event
> handling easier to read and understand.

I think using operator overloading for event handling was a bad idea.
However, no one can argue that is helps with custom data types like those
found in the SQLTypes namespace.

Other things that should be on the list...

VB.Net supports explicit Interface Mapping. This means you have to state
exactly what methods the interface method is mapped to. C# does this
auto-magically based on the method names. Considering that C# is suppose to
avoid auto-magical things, this decision confuses me.

VB.Net supports WithEvents. (Which in itself is enough of a reason to select
VB.Net over C# when programming with WinForms.)

VB.Net supports Optional parameters. They can be misused, but as long as the
defaults are obvious ones like Empty or Nothing, then there is no problem.

VB.Net supports Parameterized Properties. In C#, the only property you can
pass parameters to is the Default Indexer. A limitation I simply cannot
understand. (Note, there is a work-around in C# using inner classes, but it
is messy.)

C# supports bit shifting.

C# supports the Explicit operator. This is used to define your own type
conversions that work with the standard casting syntax. This is something
that VB really needs.

VB.Net supports Modules, also known as Function Libraries. This is useful
for stateless programming, a common technique for enterprise applications
and virtually required for Web Services. C# can simulate the same thing by
creating a class with a private constructor that is never used and setting
all the methods and fields to Static (VB Shared).

C# supports the Using block, which is helpful when you have be sure that
Dispose is called on an object. VB.Net can simulate this using a Try-Finally
block.

VB.Net supports With blocks. C# can get the same performance advantage by
using a local variable.

--
Jonathan Allen


Quote:
> Don't be so sure about knowing the "only" differences.  They are different
> languages, and these are both very complex languages. For example:

> * VB.NET support a more (arguably) powerful Select...Case instead of C#'s
> Switch...case.
> * C# support XML documentation similar to JavaDoc. IIRC VB.NET does not
> support this.
> * C# is case sensitive. This is arguably a good thing, but many from the
VB
> camp believe otherwise.
> * C# supports operator overloading.  Although some scoff at the real
> beneftis of this, many also commend it's ability to make tasks like event
> handling easier to read and understand.
> * VB.NET supports typeless "scripting". Meaning, it doesn't have to be
> strongly typed. Some call this a feature, others call it a caviat.

> C# generally has a smaller code base, and performs a bit faster (up to 5%)
> than VB.NET.  This point should NOT be considered when choosing between
> languages, rather, it should shatter the myth that all languages that use
> the CLR are the "same".  Languages that use the CLR are definatly
different
> languages beyond syntax. The benefit comes when you can compile a class in
> one language, and inherit it in another.

> You really need to find what language makes the most sense to you.  I
> strongly believe that this goes well beyond comfort of syntax. Look at the
> potential job market (will there be more VB.NET jobs or C# jobs?), look at
> each languages specific features, and look at the philosphy behind the
> design of each language, so that you can gauge the future of it.


> > The 'only' differences are:

> > C# allows unsafe code (pointers)
> > C# allows operator overloading

> > As for advice:

> > C# is very much like C++ and Java
> > VB.NET is very unlike VB6

> > I'd go for C# when fammiliar with C++\Java.
> > I'd choose VB.NET if the boss wants me to.

> > To me this means that I do both. Don't think that VB6 experience will
help
> > you to quickly and fully understand VB.NET; you will have to start all
ove
> r
> > again.

> > Good luck!

> > BTW: All .NET languages use the same .NET platform/base classes so you
> will
> > only have to learn them once!

> > Erno



Wed, 03 Mar 2004 03:03:21 GMT  
 VB.NET or C# wich one should I choose & why?
Don't forget Visual FoxPro ;)


Quote:
> > 'unsafe' <> 'unmanaged'
> > 'unsafe' code uses pointers directly. You can do this in C#, but not in
> > vb.NET.
> > 'unmanaged' code doesn't use the .NET CLR. Neither C# nor vb.NET can do
> > this.

> DUH! My bad... Should have read my post before hitting send. :-)

> Sorry for the misinformation! :(

> To even clarify further C++.NET is the only MS language under .NET to
allow
> for "unmanaged" code.

> --
> Regards,
> Cal



Wed, 03 Mar 2004 05:47:21 GMT  
 VB.NET or C# wich one should I choose & why?
How DOES FoxPro fit into the .NET scheme of things?  Since FP7 is already
out, and .NET final isnt, how does that work?
-mike


Quote:
> Don't forget Visual FoxPro ;)



> > > 'unsafe' <> 'unmanaged'
> > > 'unsafe' code uses pointers directly. You can do this in C#, but not
in
> > > vb.NET.
> > > 'unmanaged' code doesn't use the .NET CLR. Neither C# nor vb.NET can
do
> > > this.

> > DUH! My bad... Should have read my post before hitting send. :-)

> > Sorry for the misinformation! :(

> > To even clarify further C++.NET is the only MS language under .NET to
> allow
> > for "unmanaged" code.

> > --
> > Regards,
> > Cal



Wed, 03 Mar 2004 05:48:56 GMT  
 VB.NET or C# wich one should I choose & why?

Quote:
> > DUH! My bad... Should have read my post before hitting send. :-)

> > Sorry for the misinformation! :(

> > To even clarify further C++.NET is the only MS language under .NET to
> allow
> > for "unmanaged" code.

I did not know this. :-)

From some of the other articles I have ever read the have always mentioned
C++. Glad to hear that they allowed Fox Pro to continue on the in it's
tradition.

Cal



Wed, 03 Mar 2004 05:57:32 GMT  
 VB.NET or C# wich one should I choose & why?
So are we to assume that they made up quotes in the article like this?

Brian Harry, Microsoft common language runtime (CLR) product unit manager,
said: "Visual Basic will become RADish and C# more complex ... more
divergence will happen.

That sounds like a split in the roadmaps to me. I would *not* assume that a
source like ZDNet would make up something like that. Of course, Brian Harry
could have been just shooting his mouth off. But still, it does show that
people at MS are at least talking about it.
--

Ryan Farley
Lead Application Developer
Customer FX Corporation


Don't bother reading that article. The author clearly does not know what he
is talking about.

--
Jonathan Allen


Quote:
> The future may bring more differences between the two languages than there
> currently are. The following link points to an article on ZDNet that talks
> about Microsoft splitting the C# & VB.NET roadmaps (includes quotes from
> Brian Harry, Microsoft CLR product unit manager). I realize that this is
> nothing "official" from MS, but I would consider ZDNet a pretty reliable
> source.

> http://news.zdnet.co.uk/story/0,,t269-s2093679,00.html

> Anyone have more concrete info about this?
> --

> Ryan Farley
> Lead Application Developer
> Customer FX Corporation



Wed, 03 Mar 2004 10:53:54 GMT  
 
 [ 20 post ]  Go to page: [1] [2]

 Relevant Pages 

1. Can anyone help me out from choosing C# or VB.NET

2. Why I'm choosing C# over VB.NET. (as a VB programmer)

3. VS.NET: Adding one .cs file to more then one project

4. Tell me you experience in convert code from VB 6 to VB.NET or C#

5. difference betwen VC .net and C#, VB.net

6. IntelliSense in VS.NET (C# versus VB.NET)

7. Why did you choose C# as opposed to VB.NET?

8. VB to C# or C# to VB convertor

9. VB and C# are the SAME, just pick one and you learn the other anyway

10. ASP.NET using C# - Delete all files with same extension with one call

11. Why not VB.NET?

12. My one complaint with VS.NET and C#

 

 
Powered by phpBB® Forum Software