Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

VB.NET question. Linq Support?

Tags:

c#

.net

vb.net

linq

Does VB.NET have LINQ support? I was discussing VB vs C# tonight and I was told that VB is different because it does not handle web services as well as C# and that it does not support linq. Is this true?

like image 773
Moshe Avatar asked Jul 04 '26 17:07

Moshe


2 Answers

VB.NET definitely supports LINQ syntax. As far as web services are concerned I see no relation with LINQ.

like image 64
Darin Dimitrov Avatar answered Jul 06 '26 08:07

Darin Dimitrov


Yes, VB supports LINQ:

  • Its query expressions are actually richer than C#'s, in that there are various LINQ operators which are directly supported where you'd have to call the extension method directly in C#
  • It supports using extension methods as well, so you can still do things that the query expressions can't express

One area it does fall down on a bit is the conciseness of lambda expressions: from what I remember, VB9 didn't support anonymous functions with full bodies, and even in VB10 it ends up being wordier than C#.

I haven't used web services from VB, but I would be wary of accepting the truth of the claim that it doesn't handle them as well as C# if the source is the same one that told you it doesn't support LINQ...

like image 31
Jon Skeet Avatar answered Jul 06 '26 08:07

Jon Skeet



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!