473,770 Members | 5,426 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Not Another C# Versus VB Article (It has a lot to say about Anders and Delphi)

38 1742
How about translating the entire post!?

"Herfried K. Wagner [MVP]" <hi************ ***@gmx.at> wrote in message
news:u2******** ******@TK2MSFTN GP14.phx.gbl...
Cor,

"Cor Ligthert" <no************ @planet.nl> schrieb:
Der Artikel ist geprägt von m.E. unzutreffenden Vorurteilen und darauf
basierenden, ebenso inrichtigen Implikationen.


The article is lard by m.E. with not realistic bias and gives therefore
the same results.


"m.E." = "IMO".

;-)

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://classicvb.org/petition/>

Nov 21 '05 #31
http://babelfish.altavista.com/

Not overly accurate translations, but it makes most articles 20 - 60% more
interesting :) LOFL

"Earl" <br******@newsg roups.nospam> wrote in message
news:%2******** ********@TK2MSF TNGP10.phx.gbl. ..
How about translating the entire post!?

"Herfried K. Wagner [MVP]" <hi************ ***@gmx.at> wrote in message
news:u2******** ******@TK2MSFTN GP14.phx.gbl...
Cor,

"Cor Ligthert" <no************ @planet.nl> schrieb:
> Der Artikel ist geprägt von m.E. unzutreffenden Vorurteilen und darauf
> basierenden, ebenso inrichtigen Implikationen.

The article is lard by m.E. with not realistic bias and gives therefore
the same results.


"m.E." = "IMO".

;-)

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://classicvb.org/petition/>


Nov 21 '05 #32
Here's a rough translation (I did my best, chalk up minor mistakes to
artistic license... major ones to ignorance. Please forgive if I didn't
get it quite right) :)
IMO, this article [http://www.codeproject.com/useritems...pVersusVB.asp]
is shaped by unfounded prejudices and based upon implications that are
"off-track". I went through the trouble to thoroughly study and comment on
the points made in "Propagatio n Of Culture in NET":
| 1. VB by default allows support for late binding. Although it can be
| turned off with "Option strict", the culture is such that it's usually
| left on. This leads to numerous difficult to catch errors. C# binding
| is always early.

This has no foundation. In the professional field most developers work with
'option Strict on'. If 'option Strict' is switched off, then usually from
technical considerations, it is to access a COM object model approximatley
like the one in [MS] Office. Here, a useful secondary(?) functional
characteristic is called a disadvantage.

| 2. VB still supports the old "On error goto" construct. This leads to
| sloppy or non-existent error handling. C# supports only the superior
| try.catch error handling.

Why does the existence of one additional error handling construct lead to
sloppier or non-existent error handling? VB.NET supports the superior
C#-style 'try...catch[...finally]' with ' Try...Catch...F inally'. In error
handling, VB.NET is superior to C#, since it makes a different construct
available, which covers a better diversity of applications.

| 3. VB supports optional parameters. Although VB developers often
| list this as an advantage, it is a disadvantage because the use of
| optional parameters weakens the contract between the caller and
| the method, allowing the developer to slacken his analysis and get
| away with it until bugs creep in. [note: C# param array construct is
| not the same as optional params]

Again this is not correct. VB supports optional parameters as a
secondary(?) functional characteristic. Sometimes within implementations
optional parameters prove useful. Don't forget there is also the "Overloads
Hell". You can compare the overloads of 'MessageBox.Sho w' with 'MsgBox',
with the former one must scroll through numerous overloading pages, until
you find the correct one, whereas you will find only one signature form with
'MsgBox' with several optional parameters. It is not disputed that
overloaded, in some cases is advisable. Instead of using too many
overloaded methods, however, optional parameters with their own, more
appropriate and more specific names are also provided. In no case there is
only one ideal solution.

| 4. VB supports the legacy VB functions, with reference to Microsoft.
| VisualBasic.dll . Many of these functions are slow and they should all
| be avoided in favor of the .NET framework. However many VB programmers
| still use them. In new VB projects, this dangerous namespace is included
| by default.

There are no recommendations on the part of Microsoft not to use
functionality from "Microsoft.Visu alBasic.dll". "Microsoft.Visu alBasic.dll"
can be seen as "language extension" of VB.NET and is just as
sensible/clear(?) as 'using' in C#. The namespace 'Microsoft.Visu alBasic'
is in no way "dangerous" , even if some of the functions are somewhat slower
than those of the .NET Framework, some of the functions in this namespace
are not provided at all in the .NET Framework (mathematics of finance,
'Left', 'right', 'fixed', 'Split' with character sequences as disconnecting
switches, etc...) and/or these functions are faster than those of the .NET
Framework.

| 5. VB allows implementation of interfaces with methods of different
| names, making it confusing and difficult to find the implementation. C#
| does not.

Due to the explicit implementation syntax of VB.NET ('Implements') it is
obvious which method of the class implements which interface method. In C #
this is not obvious, since the definition (?) of a method does not say
whether it was implemented as a method of an interface or established as
new.

| 6. VB supports background compilation. While this speeds the
development
| cycle for small projects, it slows down the IDE in large projects,
contributing
| at least in part to the culture tending to gravitate toward small
projects.

That applied unfortunately to VB.NET 2002, in version 2003 the situation was
substantially corrected. In VB it will probably still give some
improvements in regard to the speed of the background compiling to [VB.NET]
2005. If necessary, re-referencing projects (clean reference) can also give
an improvement.

| 7. C# namespaces are managed in way that makes programmers aware
| of namespaces and their importance. VB namespaces are managed in a
| way that hides them from the programmers by default. Careful attention
| to namespace management is a fundamental tenet of strong application
| design and its importance cannot be overestimated.

Using namespaces in VB.NET exactly the same as in C# prevents absolutely
nothing.

An unprofessional (?) developer will write bad code in both C# and VB.NET, a
good developer can write good code in in both programming languages.
Optional operators of a programming language are an advantage if they
support the professional user in his/her work. They are not bad, because a
fool does not know to use them correctly.

Translated from post by M S Herfried K. Wagner, M V P

"Earl" <br******@newsg roups.nospam> wrote in message
news:%2******** ********@TK2MSF TNGP10.phx.gbl. ..
How about translating the entire post!?

"Herfried K. Wagner [MVP]" <hi************ ***@gmx.at> wrote in message
news:u2******** ******@TK2MSFTN GP14.phx.gbl...
Cor,

"Cor Ligthert" <no************ @planet.nl> schrieb:
> Der Artikel ist geprägt von m.E. unzutreffenden Vorurteilen und darauf
> basierenden, ebenso inrichtigen Implikationen.

The article is lard by m.E. with not realistic bias and gives therefore
the same results.


"m.E." = "IMO".

;-)

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://classicvb.org/petition/>


Nov 21 '05 #33
Pretty darn good translation, from the looks of it! Thanks Michael.

"Michael C#" <xy*@abcdef.com > wrote in message
news:Nk******** ******@fe08.lga ...
Here's a rough translation (I did my best, chalk up minor mistakes to
artistic license... major ones to ignorance. Please forgive if I didn't
get it quite right) :)
IMO, this article
[http://www.codeproject.com/useritems...pVersusVB.asp] is shaped by
unfounded prejudices and based upon implications that are "off-track". I
went through the trouble to thoroughly study and comment on the points
made in "Propagatio n Of Culture in NET":
| 1. VB by default allows support for late binding. Although it can be
| turned off with "Option strict", the culture is such that it's usually
| left on. This leads to numerous difficult to catch errors. C# binding
| is always early.

This has no foundation. In the professional field most developers work
with 'option Strict on'. If 'option Strict' is switched off, then usually
from technical considerations, it is to access a COM object model
approximatley like the one in [MS] Office. Here, a useful secondary(?)
functional characteristic is called a disadvantage.

| 2. VB still supports the old "On error goto" construct. This leads to
| sloppy or non-existent error handling. C# supports only the superior
| try.catch error handling.

Why does the existence of one additional error handling construct lead to
sloppier or non-existent error handling? VB.NET supports the superior
C#-style 'try...catch[...finally]' with ' Try...Catch...F inally'. In error
handling, VB.NET is superior to C#, since it makes a different construct
available, which covers a better diversity of applications.

| 3. VB supports optional parameters. Although VB developers often
| list this as an advantage, it is a disadvantage because the use of
| optional parameters weakens the contract between the caller and
| the method, allowing the developer to slacken his analysis and get
| away with it until bugs creep in. [note: C# param array construct is
| not the same as optional params]

Again this is not correct. VB supports optional parameters as a
secondary(?) functional characteristic. Sometimes within implementations
optional parameters prove useful. Don't forget there is also the
"Overloads Hell". You can compare the overloads of 'MessageBox.Sho w' with
'MsgBox', with the former one must scroll through numerous overloading
pages, until you find the correct one, whereas you will find only one
signature form with 'MsgBox' with several optional parameters. It is not
disputed that overloaded, in some cases is advisable. Instead of using
too many overloaded methods, however, optional parameters with their own,
more appropriate and more specific names are also provided. In no case
there is only one ideal solution.

| 4. VB supports the legacy VB functions, with reference to Microsoft.
| VisualBasic.dll . Many of these functions are slow and they should all
| be avoided in favor of the .NET framework. However many VB programmers
| still use them. In new VB projects, this dangerous namespace is
included
| by default.

There are no recommendations on the part of Microsoft not to use
functionality from "Microsoft.Visu alBasic.dll".
"Microsoft.Visu alBasic.dll" can be seen as "language extension" of VB.NET
and is just as sensible/clear(?) as 'using' in C#. The namespace
'Microsoft.Visu alBasic' is in no way "dangerous" , even if some of the
functions are somewhat slower than those of the .NET Framework, some of
the functions in this namespace are not provided at all in the .NET
Framework (mathematics of finance, 'Left', 'right', 'fixed', 'Split' with
character sequences as disconnecting switches, etc...) and/or these
functions are faster than those of the .NET Framework.

| 5. VB allows implementation of interfaces with methods of different
| names, making it confusing and difficult to find the implementation. C#
| does not.

Due to the explicit implementation syntax of VB.NET ('Implements') it is
obvious which method of the class implements which interface method. In C
# this is not obvious, since the definition (?) of a method does not say
whether it was implemented as a method of an interface or established as
new.

| 6. VB supports background compilation. While this speeds the
development
| cycle for small projects, it slows down the IDE in large projects,
contributing
| at least in part to the culture tending to gravitate toward small
projects.

That applied unfortunately to VB.NET 2002, in version 2003 the situation
was substantially corrected. In VB it will probably still give some
improvements in regard to the speed of the background compiling to
[VB.NET] 2005. If necessary, re-referencing projects (clean reference) can
also give an improvement.

| 7. C# namespaces are managed in way that makes programmers aware
| of namespaces and their importance. VB namespaces are managed in a
| way that hides them from the programmers by default. Careful attention
| to namespace management is a fundamental tenet of strong application
| design and its importance cannot be overestimated.

Using namespaces in VB.NET exactly the same as in C# prevents absolutely
nothing.

An unprofessional (?) developer will write bad code in both C# and VB.NET,
a good developer can write good code in in both programming languages.
Optional operators of a programming language are an advantage if they
support the professional user in his/her work. They are not bad, because
a fool does not know to use them correctly.

Translated from post by M S Herfried K. Wagner, M V P

"Earl" <br******@newsg roups.nospam> wrote in message
news:%2******** ********@TK2MSF TNGP10.phx.gbl. ..
How about translating the entire post!?

"Herfried K. Wagner [MVP]" <hi************ ***@gmx.at> wrote in message
news:u2******** ******@TK2MSFTN GP14.phx.gbl...
Cor,

"Cor Ligthert" <no************ @planet.nl> schrieb:
>> Der Artikel ist geprägt von m.E. unzutreffenden Vorurteilen und
>> darauf
>> basierenden, ebenso inrichtigen Implikationen.

The article is lard by m.E. with not realistic bias and gives therefore
the same results.

"m.E." = "IMO".

;-)

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://classicvb.org/petition/>



Nov 21 '05 #34
Addendum:
How about translating the entire post!?


I feel sorry, but I currently don't have enough time to do that...


Based on the requests, I'll translate and extend my critique and post it in
a few hours.

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://classicvb.org/petition/>

Nov 21 '05 #35
On Tue, 24 May 2005 16:45:29 -0500, "Charles D. Quarles"
<cd*******@msn. com> wrote:
Hi Doug,

"Doug Taylor" <Do************ @tayNOSPAMmade. demon.co.uk> wrote in message
news:0b******* *************** **********@4ax. com...
On Fri, 20 May 2005 12:47:54 +1000, "Arjang"
<Ar************ ****@NotTheReal Part.zorg> wrote:
http://www.codeproject.com/useritems/CSharpVersusVB.asp
There are a few inaccuracy in the article as regards the history of
Borland Pascal, which it claims was the first commercially available
Pascal.

For the record USCD was available prior to Borland Pascal 3 and of
course Anders and Niels Kompass Pascal 1 and 2 predate Phillipe Kahn
persuading them to remarket the company as Borland (appearing to be
American rather than European) and selling the product cheaply, if I
remember correctly the UK price was £35 as compared to £250 for
version 2, with a restrictive license.

Doug Taylor


I bought a copy of Apple Pascal ca 1984. This was a version of the UCSD
pcode system. I paid $500 US for it ;) back then. What a world :).


Which translates to around $2000 in todays money.

Doug.
Charles


Nov 21 '05 #36
You'll find the translation below:
http://www.codeproject.com/useritems/CSharpVersusVB.asp


This article is IMO stamped by a number of unfounded prejudices and thus
includes some incorrect conclusions. I have taken some of the points made
in the section "Propagatio n of Culture in .NET" and commented them:

| 1. VB by default allows support for late binding. Although it can be
| turned off with "Option strict", the culture is such that it's usually
| left on. This leads to numerous difficult to catch errors. C# binding
| is always early.

This point doesn't apply to professional development. In a professional
environment, almost all developers work with 'Option Strict On', which will
make VB.NET more type-safe than C#. If 'Option Strict' is turned off, this
decision is based on technical considerations, for example, to ease access
to COM object models like those of Microsoft Office. The author of the
article constructs a disadvantage out from an additional, useful feature.

| 2. VB still supports the old "On error goto" construct. This leads to
| sloppy or non-existent error handling. C# supports only the superior
| try.catch error handling.

I don't see any reasons whe the existance of an /additional/ language
construct for error handling leads to sloppier code or non-existant error
handling. VB.NET supports 'Try...Catch' including 'When', which is superior
to C#'s 'try...catch' error handling structure. VB.NET provides advantages
over C# in matters of error/exception handling capabilities because it
provides constructs which match better with the different afforfances of
error/exception handling.

| 3. VB supports optional parameters. Although VB developers often
| list this as an advantage, it is a disadvantage because the use of
| optional parameters weakens the contract between the caller and
| the method, allowing the developer to slacken his analysis and get
| away with it until bugs creep in. [note: C# param array construct is
| not the same as optional params]

That's wrong too. VB.NET supports optional parameters as an additional
feature. Optional parameters provide advantages when used inside
implementations , and are thus useful in some situations. Don't forget that
methods using optional parameters do not suffer from the "overloads hell".
When comparing 'MsgBox' to 'MessageBox.Sho w' usability for the latter in
VS.NET is bad because you'll have to pick the right overload from a long
list. On the other hand, 'MsgBox' is a function with many optional
paramters, but usability doesn't suffer. While overloading makes sense in
some cases, I would not see it as a general replacement of optional
parameters, because makes writing code harder and will lead to
less-descriptive code. One other solution to this problem is to give the
methods more specific names instead of overloading a single, generic name.
Altogether there is not a single "best" solution, but there are many good
solution for different cases -- and optional parameters are one of them.

Overloading vs. Object Technology
<URL:http://www.inf.ethz.ch/personal/meyer/publications/joop/overloading.pdf >

| 4. VB supports the legacy VB functions, with reference to Microsoft.
| VisualBasic.dll . Many of these functions are slow and they should all
| be avoided in favor of the .NET framework. However many VB programmers
| still use them. In new VB projects, this dangerous namespace is included
| by default.

Wrong. Microsoft has never published a recommendation not to use
functionality implemented in
"Microsoft.Visu alBasic.dll". "Microsoft.Visu alBasic.dll" can be seen as a
"language extension" of the core VB.NET programming language. It's as
useful as 'using' in C# because it provides a shortcut to existing
functionality of the .NET Framework. Additionally 'Microsoft.Visu alBasic'
contains functionality which is not present in the .NET Framework, like
support for financial mathematics, 'Left', 'Right', 'Fix', 'Split' with
support for strings as separators, ..., and it's absolutely not "dangerous"
to use this functionality. Some of the functions provided in
'Microsoft.Visu alBasic' are even faster than their .NET Framework
counterparts.

| 5. VB allows implementation of interfaces with methods of different
| names, making it confusing and difficult to find the implementation. C#
| does not.

Wrong again. VB.NEt supports are more explicit syntax for interface
implementation ('Implements <interface>.<me thod>') than C#. This syntax
makes it more obviosu which method of the class implements which method of
an interface. In C# that's not obvious because there is no way to decide
whether or not a method implements a method of an interface or simply
extends the class without taking a look at the base class.

| 6. VB supports background compilation. While this speeds the
development
| cycle for small projects, it slows down the IDE in large projects,
contributing
| at least in part to the culture tending to gravitate toward small
| projects.

This was true for VB.NET 2002, but in version 2003 there were significant
speed improvements. In VB 2005 there will likely be some additional
improvements for background compilation. Splitting up the solution into
multiple projects can lead to an improved experience too.

| 7. C# namespaces are managed in way that makes programmers aware
| of namespaces and their importance. VB namespaces are managed in a
| way that hides them from the programmers by default. Careful attention
| to namespace management is a fundamental tenet of strong application
| design and its importance cannot be overestimated.

There is absolutely nothing that prevents one from using namespaces in
VB.NET the way they are used in C#.

Conclusion: An unprofessional developer will write bad code in both C# and
VB.NET, a good deveöoper will be able to write good code in both programming
languages. Optional additional language features are an advantage if the
assist a professional developer with his/her work. They are not bad only
because an unprofessional developer doesn't know how and when to use them.

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://classicvb.org/petition/>

Nov 21 '05 #37
Sorry I butchered it so badly :) The newer "technical" terms mess me up
quite a bit. It took me three passes to figure out "namespaces " (I kept
seeing "name area" LOL). Thanks for the good translation!

"Herfried K. Wagner [MVP]" <hi************ ***@gmx.at> wrote in message
news:uz******** ******@TK2MSFTN GP15.phx.gbl...
You'll find the translation below:
http://www.codeproject.com/useritems/CSharpVersusVB.asp


This article is IMO stamped by a number of unfounded prejudices and thus
includes some incorrect conclusions. I have taken some of the points made
in the section "Propagatio n of Culture in .NET" and commented them:

| 1. VB by default allows support for late binding. Although it can be
| turned off with "Option strict", the culture is such that it's usually
| left on. This leads to numerous difficult to catch errors. C# binding
| is always early.

This point doesn't apply to professional development. In a professional
environment, almost all developers work with 'Option Strict On', which
will make VB.NET more type-safe than C#. If 'Option Strict' is turned
off, this decision is based on technical considerations, for example, to
ease access to COM object models like those of Microsoft Office. The
author of the article constructs a disadvantage out from an additional,
useful feature.

| 2. VB still supports the old "On error goto" construct. This leads to
| sloppy or non-existent error handling. C# supports only the superior
| try.catch error handling.

I don't see any reasons whe the existance of an /additional/ language
construct for error handling leads to sloppier code or non-existant error
handling. VB.NET supports 'Try...Catch' including 'When', which is
superior to C#'s 'try...catch' error handling structure. VB.NET provides
advantages over C# in matters of error/exception handling capabilities
because it provides constructs which match better with the different
afforfances of error/exception handling.

| 3. VB supports optional parameters. Although VB developers often
| list this as an advantage, it is a disadvantage because the use of
| optional parameters weakens the contract between the caller and
| the method, allowing the developer to slacken his analysis and get
| away with it until bugs creep in. [note: C# param array construct is
| not the same as optional params]

That's wrong too. VB.NET supports optional parameters as an additional
feature. Optional parameters provide advantages when used inside
implementations , and are thus useful in some situations. Don't forget
that methods using optional parameters do not suffer from the "overloads
hell". When comparing 'MsgBox' to 'MessageBox.Sho w' usability for the
latter in VS.NET is bad because you'll have to pick the right overload
from a long list. On the other hand, 'MsgBox' is a function with many
optional paramters, but usability doesn't suffer. While overloading makes
sense in some cases, I would not see it as a general replacement of
optional parameters, because makes writing code harder and will lead to
less-descriptive code. One other solution to this problem is to give the
methods more specific names instead of overloading a single, generic name.
Altogether there is not a single "best" solution, but there are many good
solution for different cases -- and optional parameters are one of them.

Overloading vs. Object Technology
<URL:http://www.inf.ethz.ch/personal/meyer/publications/joop/overloading.pdf >

| 4. VB supports the legacy VB functions, with reference to Microsoft.
| VisualBasic.dll . Many of these functions are slow and they should all
| be avoided in favor of the .NET framework. However many VB programmers
| still use them. In new VB projects, this dangerous namespace is
included
| by default.

Wrong. Microsoft has never published a recommendation not to use
functionality implemented in
"Microsoft.Visu alBasic.dll". "Microsoft.Visu alBasic.dll" can be seen as a
"language extension" of the core VB.NET programming language. It's as
useful as 'using' in C# because it provides a shortcut to existing
functionality of the .NET Framework. Additionally 'Microsoft.Visu alBasic'
contains functionality which is not present in the .NET Framework, like
support for financial mathematics, 'Left', 'Right', 'Fix', 'Split' with
support for strings as separators, ..., and it's absolutely not
"dangerous" to use this functionality. Some of the functions provided in
'Microsoft.Visu alBasic' are even faster than their .NET Framework
counterparts.

| 5. VB allows implementation of interfaces with methods of different
| names, making it confusing and difficult to find the implementation. C#
| does not.

Wrong again. VB.NEt supports are more explicit syntax for interface
implementation ('Implements <interface>.<me thod>') than C#. This syntax
makes it more obviosu which method of the class implements which method of
an interface. In C# that's not obvious because there is no way to decide
whether or not a method implements a method of an interface or simply
extends the class without taking a look at the base class.

| 6. VB supports background compilation. While this speeds the
development
| cycle for small projects, it slows down the IDE in large projects,
contributing
| at least in part to the culture tending to gravitate toward small
| projects.

This was true for VB.NET 2002, but in version 2003 there were significant
speed improvements. In VB 2005 there will likely be some additional
improvements for background compilation. Splitting up the solution into
multiple projects can lead to an improved experience too.

| 7. C# namespaces are managed in way that makes programmers aware
| of namespaces and their importance. VB namespaces are managed in a
| way that hides them from the programmers by default. Careful attention
| to namespace management is a fundamental tenet of strong application
| design and its importance cannot be overestimated.

There is absolutely nothing that prevents one from using namespaces in
VB.NET the way they are used in C#.

Conclusion: An unprofessional developer will write bad code in both C#
and VB.NET, a good deveöoper will be able to write good code in both
programming languages. Optional additional language features are an
advantage if the assist a professional developer with his/her work. They
are not bad only because an unprofessional developer doesn't know how and
when to use them.

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://classicvb.org/petition/>

Nov 21 '05 #38
Thanks for the translation Herfried. A damn fair analysis, I might add!

"Herfried K. Wagner [MVP]" <hi************ ***@gmx.at> wrote in message
news:uz******** ******@TK2MSFTN GP15.phx.gbl...
You'll find the translation below:
http://www.codeproject.com/useritems/CSharpVersusVB.asp


This article is IMO stamped by a number of unfounded prejudices and thus
includes some incorrect conclusions. I have taken some of the points made
in the section "Propagatio n of Culture in .NET" and commented them:

| 1. VB by default allows support for late binding. Although it can be
| turned off with "Option strict", the culture is such that it's usually
| left on. This leads to numerous difficult to catch errors. C# binding
| is always early.

This point doesn't apply to professional development. In a professional
environment, almost all developers work with 'Option Strict On', which
will make VB.NET more type-safe than C#. If 'Option Strict' is turned
off, this decision is based on technical considerations, for example, to
ease access to COM object models like those of Microsoft Office. The
author of the article constructs a disadvantage out from an additional,
useful feature.

| 2. VB still supports the old "On error goto" construct. This leads to
| sloppy or non-existent error handling. C# supports only the superior
| try.catch error handling.

I don't see any reasons whe the existance of an /additional/ language
construct for error handling leads to sloppier code or non-existant error
handling. VB.NET supports 'Try...Catch' including 'When', which is
superior to C#'s 'try...catch' error handling structure. VB.NET provides
advantages over C# in matters of error/exception handling capabilities
because it provides constructs which match better with the different
afforfances of error/exception handling.

| 3. VB supports optional parameters. Although VB developers often
| list this as an advantage, it is a disadvantage because the use of
| optional parameters weakens the contract between the caller and
| the method, allowing the developer to slacken his analysis and get
| away with it until bugs creep in. [note: C# param array construct is
| not the same as optional params]

That's wrong too. VB.NET supports optional parameters as an additional
feature. Optional parameters provide advantages when used inside
implementations , and are thus useful in some situations. Don't forget
that methods using optional parameters do not suffer from the "overloads
hell". When comparing 'MsgBox' to 'MessageBox.Sho w' usability for the
latter in VS.NET is bad because you'll have to pick the right overload
from a long list. On the other hand, 'MsgBox' is a function with many
optional paramters, but usability doesn't suffer. While overloading makes
sense in some cases, I would not see it as a general replacement of
optional parameters, because makes writing code harder and will lead to
less-descriptive code. One other solution to this problem is to give the
methods more specific names instead of overloading a single, generic name.
Altogether there is not a single "best" solution, but there are many good
solution for different cases -- and optional parameters are one of them.

Overloading vs. Object Technology
<URL:http://www.inf.ethz.ch/personal/meyer/publications/joop/overloading.pdf >

| 4. VB supports the legacy VB functions, with reference to Microsoft.
| VisualBasic.dll . Many of these functions are slow and they should all
| be avoided in favor of the .NET framework. However many VB programmers
| still use them. In new VB projects, this dangerous namespace is
included
| by default.

Wrong. Microsoft has never published a recommendation not to use
functionality implemented in
"Microsoft.Visu alBasic.dll". "Microsoft.Visu alBasic.dll" can be seen as a
"language extension" of the core VB.NET programming language. It's as
useful as 'using' in C# because it provides a shortcut to existing
functionality of the .NET Framework. Additionally 'Microsoft.Visu alBasic'
contains functionality which is not present in the .NET Framework, like
support for financial mathematics, 'Left', 'Right', 'Fix', 'Split' with
support for strings as separators, ..., and it's absolutely not
"dangerous" to use this functionality. Some of the functions provided in
'Microsoft.Visu alBasic' are even faster than their .NET Framework
counterparts.

| 5. VB allows implementation of interfaces with methods of different
| names, making it confusing and difficult to find the implementation. C#
| does not.

Wrong again. VB.NEt supports are more explicit syntax for interface
implementation ('Implements <interface>.<me thod>') than C#. This syntax
makes it more obviosu which method of the class implements which method of
an interface. In C# that's not obvious because there is no way to decide
whether or not a method implements a method of an interface or simply
extends the class without taking a look at the base class.

| 6. VB supports background compilation. While this speeds the
development
| cycle for small projects, it slows down the IDE in large projects,
contributing
| at least in part to the culture tending to gravitate toward small
| projects.

This was true for VB.NET 2002, but in version 2003 there were significant
speed improvements. In VB 2005 there will likely be some additional
improvements for background compilation. Splitting up the solution into
multiple projects can lead to an improved experience too.

| 7. C# namespaces are managed in way that makes programmers aware
| of namespaces and their importance. VB namespaces are managed in a
| way that hides them from the programmers by default. Careful attention
| to namespace management is a fundamental tenet of strong application
| design and its importance cannot be overestimated.

There is absolutely nothing that prevents one from using namespaces in
VB.NET the way they are used in C#.

Conclusion: An unprofessional developer will write bad code in both C#
and VB.NET, a good deveöoper will be able to write good code in both
programming languages. Optional additional language features are an
advantage if the assist a professional developer with his/her work. They
are not bad only because an unprofessional developer doesn't know how and
when to use them.

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://classicvb.org/petition/>

Nov 21 '05 #39

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

31
4807
by: surfunbear | last post by:
I've read some posts on Perl versus Python and studied a bit of my Python book. I'm a software engineer, familiar with C++ objected oriented development, but have been using Perl because it is great for pattern matching, text processing, and automated testing. Our company is really fixated on risk managnemt and the only way I can do enough testing without working overtime (which some people have ended up doing) is by automating my...
14
3980
by: Hafez | last post by:
Hi there every body I'm new in programming in windows. I know how to program with C and C++ in DOS but I don't know select which one for programming in windows: Visual C++ ,C# or Delphi. thanks.
6
3169
by: Erva | last post by:
Hi, Is there someone who has moved from Delphi to VS.NET? I'am using Delphi currently but seriously considering to moving VS.NET. I would like to hear if someone has already done that, is it worth of it or should i continue to ude Delphi for new projects. I'am developing mostly desktop apps but in th future also ASP.NET apps. -erva
48
3524
by: Andrew Quine | last post by:
Hi Just read this article http://www.artima.com/intv/choices.html. Towards the end of the dicussions, when asked "Did you consider including support for the concept of immutable directly in C# and the CLR?" Anders' reply included this comment: "The concept of an immutable object is very useful, but it's just up to the author to say that it's immutable."
3
2369
by: lukeharpin | last post by:
Currently I have been developing applications in Delphi 7. Recently I meet up with a friend of mine who previously developed in Delphi, from version 1 - 7. When Delphi 8 .net was release he found too many bugs and switch to C# and loves it. I hope to do the same. However, I have a few hurdles to jump. Firstly my boss is a Delphi nut. I have heard the guy who originally developed Delphi worked on the development of C# ? If so this maybe...
21
1963
by: matko | last post by:
As far as I can see, there is no similar way of replicating the following Delphi-code in C#... Is that true? type IntRange = -5..5; CharRange = 'a'..'z'; TColors = (Red, White, Green, Blue, Yellow); ColorRange = White..Blue;
135
7524
by: Xah Lee | last post by:
Tabs versus Spaces in Source Code Xah Lee, 2006-05-13 In coding a computer program, there's often the choices of tabs or spaces for code indentation. There is a large amount of confusion about which is better. It has become what's known as “religious war†— a heated fight over trivia. In this essay, i like to explain what is the situation behind it, and which is proper.
7
2437
by: dktekno | last post by:
I have tried C++ Builder and Delphi and Visual Studio. What are the reasons people do not like Delphi and would rather develop in C++? C++ compilers are so.. pedantic and so slowy. In Pascal there is a room for errors like typos, like if you declared a variable A and then you write a later, then it understands what you mean. C++ is case sensitive. C++ is slow to compile. Few lines = slow compilation. In Delphi, the compile time is rather...
14
3888
by: ApexData | last post by:
I am considering building some distributable commercial applications. For about a year now, I have been using Access2000. This was my first venture into object oriented database development. Having a background in Pascal and some C++, I would have preferred those languages, but VBA made do. The SQL was fine. I believe that Security issues on the backend, and data integrity/ corruption complaints over the network may be a stumbling...
0
9595
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9432
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10232
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10059
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10008
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
1
7420
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5313
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
1
3974
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3578
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.