Great Confusing Problem with VB.NET developers
-
Only once i went to a city which is far from here and i stayed there 3 months and from there i came to know vb don,t have demand in markete. After this i searched internet and i found vb realy don,t have demand in markete.
There is a demand. Not a big demand, but it's there. All our new projects are in C# but we have legacy VB.NET apps, including one set of web services we just worked on to handle our migration from AS/400 to Oracle. There are probably a lot of shops like ours. Do learn C#, though. I fought it for years, and now I love it. I do miss certain functions from VB, though.
If you think 'goto' is evil, try writing an Assembly program without JMP.
-
Jörgen Andersson wrote:
I'll just mention
dynamic
thenPlease, don't.
var
was bad enough, but at least it has a need - Linq won't work without it.dynamic
is a retrograde step IMO.Jörgen Andersson wrote:
Ever seen an empty catch?
On Error Resume Next is like an invisible empty catch block round every single line of code...empty catch is bad enough, but when you can't even see them? :laugh:
Jörgen Andersson wrote:
Don't blame crappy programming on the language.
I don't: you can write cr@p code in any language and (with a bit of work sometimes) you can write excellent code in every language. But some languages encourage good code, by making it harder to make mistakes. And some languages encourage cr@p code by making it harder to do things properly!
Bad command or file name. Bad, bad command! Sit! Stay! Staaaay...
OriginalGriff wrote:
var
was bad enough, but at least it has a need - Linq won't work without itReally? I'm not having a good enough understanding of the plumbing behind Linq to be able to say you're wrong, but you can always select real types instead of anonymous types if you want to. But yeah, the freaks that are known as linq to SQL spit and Linq to XML might be a different story.
OriginalGriff wrote:
Error Resume Next is like an invisible empty catch block
It's rather quite visible. The problem is rather, that actually handling errors in old VB was even worse. Just taste the syntax "On Error Goto ...", yes it says GOTO :wtf: I don't understand the need to always be backward compatible.
Wrong is evil and must be defeated. - Jeff Ello
-
Jörgen Andersson wrote:
Ever seen an empty catch?
Hey! You been lookin' at my code?!
If you think 'goto' is evil, try writing an Assembly program without JMP.
There are perfectly legitimate reasons to have an empty catch block. Just can't think of any right now. :)
Wrong is evil and must be defeated. - Jeff Ello
-
Bro! You are absolutely right. There are many commands in vb which can,t be converted in C# but most people don,t accept this reality. I am also feeling myself a newbie and worrying about it. I never think i can,t do something in programming but when i look to markete then this reality comes that vb don,t have demand. With passing time while i am practicing c# i am found that it is realy becoming easy for but in heart i still prefer vb upon c#.
Yeah, I have seen this discussed from time to time. For Microsoft, VB.net carries almost no expense as they do not have to maintain a separate compiler. Visual Studio just translates both C# and VB.net into the intermediate language (CIL?) which then gets compiled. (Actually I have heard C# described as C++ with VB goodness baked inside). Interestingly, according to TIOBE this month VB.net ranks #7, between Python at #6 and PHP at #8. Even Visual Basic (VB6?) ranks at #11 just above Perl. There are a lot of prejudices out there. I have noticed hard-core C programmers tend to look down their noses at C++ and C# folks. Then again Assembler programmers tend to look down on all the Compiler folks (C included), who in turn tend to look down on folks using Interpreted languages. Then again I am sure that 50 years ago there were folks entering programs on the register switches in front of computers back then who thought the Assembler folks were clots (I did this once, no great fun tho). In short, Member 9993589, welcome to programming!
-
Appologize if this is childish question but i am in too much confusion. I learnt first language vb6.0 in 2008 then i was student later and i continue it many years then 2 years ago i shifted to vb.net but in markete there is demand of c#. Many peoples told that c# is better than vb.net that,s why there is no value of vb.net in markete. I still can,t find any job to work in vb.net while i know vb well. Then i learnt C++ and i learnt it well and then i moved to c# and now i can code in c#. But problem is that i can,t code in c# same as in vb.net. I mean i always prefer vb. In vb i can solve any problem. but in c# i have to search from start and i don,t know why i like vb.net too much. In other words i don,t want to leave vb but markete always force to work in c# and foget vb. If vb is too bad in markete then why microsoft still supports it. Microsoft must close vb because they can,t give good markete to vb. Due to this reasons vb only developers are still poor in markete. They can switch to c# easly but their hearts shall always stick with vb. I know many languages like vb,c#,java,asp.net,php,mysql,sql etc but my heart always stick with vb. When i code in other language except vb then i always think to do that task in vb also. I love vb but what should i do while markete don,t have demand of vb?
I have similar sentiments and history. I started (professionally) in VB 3/4 back in the late 90s. I also know a dozen different languages and several platforms. I was forced into C# about 3ish years ago. The kicker is I actually agreed with the move; it made good business sense… and made me a bit sad. I’ll always be in love with BASIC. Its current face is VB.NET, but who knows where that’ll be in the future. The simple truth is that Microsoft backs C# more than VB. As I recall, in .Net Rocks Episode # 1140 (@ 43 minutes) Jay Schmelzer talks about how new language features will usually be in C# first, then added to the others. It’s sucks, but that’s the way it is. Quell the automatic reaction and ask yourself why. My opinion is that it is Java’s fault. Microsoft is trying to attract Java devs to .NET. C# can get that job done, VB can’t.
Quote:
Many peoples told that c# is better than vb.net...
Anybody who says C# is “better” than VB.net is an idiot. (Or even VB.net is “better” than C#) They simply don’t understand the .NET platform. Inform them if you can, but try not to argue. It’ll make you look as dumb as them. Microsoft’s brilliance is .NET… not VB, C#, or F#. They are just tools.
Quote:
But problem is that i can,t code in c# same as in vb.net
I also tended to write code in VB, and then translate into to C#. Practice will make it more nature.
Quote:
I love vb but what should i do while markete don,t have demand of vb?
People still write COBOL!!! They’re not as many COBOL jobs today, but they still exist. They’ll also be harder to find. I’d suggest figuring out what you want to do: be a VB.NET specialist or a generalist able to do both VB and C#. Then take a look at the job market(s) you have access to. Do enough possible jobs exist to support a specialist? If it does, then raise your rates and apply. If it doesn’t, well, either become a generalist or move to a different market.
- great coders make code look easy - When humans are doing things computers could be doing instead, the computers get together late at night and laugh at us. - ¿Neal Ford?
-
Appologize if this is childish question but i am in too much confusion. I learnt first language vb6.0 in 2008 then i was student later and i continue it many years then 2 years ago i shifted to vb.net but in markete there is demand of c#. Many peoples told that c# is better than vb.net that,s why there is no value of vb.net in markete. I still can,t find any job to work in vb.net while i know vb well. Then i learnt C++ and i learnt it well and then i moved to c# and now i can code in c#. But problem is that i can,t code in c# same as in vb.net. I mean i always prefer vb. In vb i can solve any problem. but in c# i have to search from start and i don,t know why i like vb.net too much. In other words i don,t want to leave vb but markete always force to work in c# and foget vb. If vb is too bad in markete then why microsoft still supports it. Microsoft must close vb because they can,t give good markete to vb. Due to this reasons vb only developers are still poor in markete. They can switch to c# easly but their hearts shall always stick with vb. I know many languages like vb,c#,java,asp.net,php,mysql,sql etc but my heart always stick with vb. When i code in other language except vb then i always think to do that task in vb also. I love vb but what should i do while markete don,t have demand of vb?
VB made you soft and weak, now you pay the price for ignoring advice.
-
OriginalGriff wrote:
var
was bad enough, but at least it has a need - Linq won't work without itReally? I'm not having a good enough understanding of the plumbing behind Linq to be able to say you're wrong, but you can always select real types instead of anonymous types if you want to. But yeah, the freaks that are known as linq to SQL spit and Linq to XML might be a different story.
OriginalGriff wrote:
Error Resume Next is like an invisible empty catch block
It's rather quite visible. The problem is rather, that actually handling errors in old VB was even worse. Just taste the syntax "On Error Goto ...", yes it says GOTO :wtf: I don't understand the need to always be backward compatible.
Wrong is evil and must be defeated. - Jeff Ello
Afraid so - Linq works by creating anonymous types which are specific to the query - so if you don't have a "define this from context" variable type it can't do things like this:
var v = myCollection.Where(w => w.ID < 10).Select(s => new {ID = s.ID, Name = s.Name});
Because you can't declare
IEnumerable<WhatNameWillTheCompilerGiveThatDamnThing> v = ...
It only annoys me when people use it as a shortcut datatype:
var v = 123;
Or to be really annoying
var v = GetSomething(somethingElse);
because it may save you 5 seconds typing, but I'm going to have to hunt down the method declaration to try and work out the heck you are doing... :mad:
Bad command or file name. Bad, bad command! Sit! Stay! Staaaay...
-
Appologize if this is childish question but i am in too much confusion. I learnt first language vb6.0 in 2008 then i was student later and i continue it many years then 2 years ago i shifted to vb.net but in markete there is demand of c#. Many peoples told that c# is better than vb.net that,s why there is no value of vb.net in markete. I still can,t find any job to work in vb.net while i know vb well. Then i learnt C++ and i learnt it well and then i moved to c# and now i can code in c#. But problem is that i can,t code in c# same as in vb.net. I mean i always prefer vb. In vb i can solve any problem. but in c# i have to search from start and i don,t know why i like vb.net too much. In other words i don,t want to leave vb but markete always force to work in c# and foget vb. If vb is too bad in markete then why microsoft still supports it. Microsoft must close vb because they can,t give good markete to vb. Due to this reasons vb only developers are still poor in markete. They can switch to c# easly but their hearts shall always stick with vb. I know many languages like vb,c#,java,asp.net,php,mysql,sql etc but my heart always stick with vb. When i code in other language except vb then i always think to do that task in vb also. I love vb but what should i do while markete don,t have demand of vb?
You go right ahead and stick with VB if that's what you're comfortable writing (particularly if you're 'on your own' consulting. The client doesn't care what language you use!) I've written (and still do) professional VB (both VB6 and .Net) as well as a lot of C#. I write some Javascript, spent about 15 years writing C/C++ and a dozen or so writing assembly, and even FORTRAN (back in the 'old' days). Unless you're in some shop that REQUIRES you use a particular language for development (or trying to impress someone with esoteric or terse looking code) rather than getting RESULTS then, as I said, use the one you like. Personally I think VB has some real charm to it (as well as being just as functional as C#). There's a lot of language bigots out there. Just ignore them. -CM :-)
-
I have similar sentiments and history. I started (professionally) in VB 3/4 back in the late 90s. I also know a dozen different languages and several platforms. I was forced into C# about 3ish years ago. The kicker is I actually agreed with the move; it made good business sense… and made me a bit sad. I’ll always be in love with BASIC. Its current face is VB.NET, but who knows where that’ll be in the future. The simple truth is that Microsoft backs C# more than VB. As I recall, in .Net Rocks Episode # 1140 (@ 43 minutes) Jay Schmelzer talks about how new language features will usually be in C# first, then added to the others. It’s sucks, but that’s the way it is. Quell the automatic reaction and ask yourself why. My opinion is that it is Java’s fault. Microsoft is trying to attract Java devs to .NET. C# can get that job done, VB can’t.
Quote:
Many peoples told that c# is better than vb.net...
Anybody who says C# is “better” than VB.net is an idiot. (Or even VB.net is “better” than C#) They simply don’t understand the .NET platform. Inform them if you can, but try not to argue. It’ll make you look as dumb as them. Microsoft’s brilliance is .NET… not VB, C#, or F#. They are just tools.
Quote:
But problem is that i can,t code in c# same as in vb.net
I also tended to write code in VB, and then translate into to C#. Practice will make it more nature.
Quote:
I love vb but what should i do while markete don,t have demand of vb?
People still write COBOL!!! They’re not as many COBOL jobs today, but they still exist. They’ll also be harder to find. I’d suggest figuring out what you want to do: be a VB.NET specialist or a generalist able to do both VB and C#. Then take a look at the job market(s) you have access to. Do enough possible jobs exist to support a specialist? If it does, then raise your rates and apply. If it doesn’t, well, either become a generalist or move to a different market.
- great coders make code look easy - When humans are doing things computers could be doing instead, the computers get together late at night and laugh at us. - ¿Neal Ford?
You spoke golden words. It is really nice answer that if markete have demand of vb specialist then i should become vb specialist other wise i should be a generalist and should work in both vb and c#. But here c# has more preference so i should become generalist. But it is reality i can code more better than c#.
-
Forget all the haters. VB.net is a great echo system; unfortunately it got the name "VB" in it and the holy wars happened. The MS started pushing C# as the end all be all, but vb.net and C# are equivalent. the second issue for the holly war is C# name (and code) looks like C, C++; so people (shops) tend to equate C# = C++ (fast and efficient) and VB.net = VB6 (hobbyist and interpreted code). It's stupid, I know. We all (should) know C#=VB.net close to 95%; one is not faster then the other since they both exist on the same runtime. If VB.net had been named something like: N# and C# named something like O#, no one would be having this argument right now. and equal shops would be hiring for both N# and O#; preference being if you like "}" or "end sub" That said we all have to work; so you do what you have to. Luckily I work for a place that let me choose the direction for all new projects; so it's almost always VB.net. But I still like messing with C (sorry guys C++ feels too messy too me) and Dlang.org looks promising.
Yes there is difference only of names. Many times when i talk to non programmers about langauges and tell them about visual basic they always focus on word "basic" and think it is a basic language only and it is not advanced language it is just basic language. While C# reputation is hidden in it,s name, when people listen c# they think it is C/C++ or same like this.
-
Afraid so - Linq works by creating anonymous types which are specific to the query - so if you don't have a "define this from context" variable type it can't do things like this:
var v = myCollection.Where(w => w.ID < 10).Select(s => new {ID = s.ID, Name = s.Name});
Because you can't declare
IEnumerable<WhatNameWillTheCompilerGiveThatDamnThing> v = ...
It only annoys me when people use it as a shortcut datatype:
var v = 123;
Or to be really annoying
var v = GetSomething(somethingElse);
because it may save you 5 seconds typing, but I'm going to have to hunt down the method declaration to try and work out the heck you are doing... :mad:
Bad command or file name. Bad, bad command! Sit! Stay! Staaaay...
And if you don't create anonymous types? You'll get:
Person v = myCollection.Where(w => w.ID < 10).Select(s => new Person {ID = s.ID, Name = s.Name});
Works just fine converting types this way too, consider:
class Program { static void Main(string\[\] args) { List SalesPersons = new List(); SalesPersons.Add(new SalesPerson { ID = 1, Name = "Adam", IQ = 30 }); SalesPersons.Add(new SalesPerson { ID = 2, Name = "Benny", IQ = 40 }); SalesPersons.Add(new SalesPerson { ID = 3, Name = "Cunt", IQ = 20 }); List Persons = SalesPersons.Where(item => item.Name.StartsWith("B")).Select(item => new Person { ID = item.ID, Name = item.Name }).ToList(); Console.WriteLine(Persons.FirstOrDefault().Name); Console.ReadKey(); } } public class Person { public int ID { get; set; } public string Name { get; set; } } public class SalesPerson { public int ID { get; set; } public string Name { get; set; } public int IQ { get; set; } }
Nothing anonymous there. I do that a lot since I hate the fact that anonymous classes are local to the method they're created in. So Ok that was not entirely true, you can actually pass anonymous types between methods, if you reuse the definition the compiler actually reuses the anonymous class. But that would require a lot of casting.
Wrong is evil and must be defeated. - Jeff Ello
-
VB made you soft and weak, now you pay the price for ignoring advice.
-
Appologize if this is childish question but i am in too much confusion. I learnt first language vb6.0 in 2008 then i was student later and i continue it many years then 2 years ago i shifted to vb.net but in markete there is demand of c#. Many peoples told that c# is better than vb.net that,s why there is no value of vb.net in markete. I still can,t find any job to work in vb.net while i know vb well. Then i learnt C++ and i learnt it well and then i moved to c# and now i can code in c#. But problem is that i can,t code in c# same as in vb.net. I mean i always prefer vb. In vb i can solve any problem. but in c# i have to search from start and i don,t know why i like vb.net too much. In other words i don,t want to leave vb but markete always force to work in c# and foget vb. If vb is too bad in markete then why microsoft still supports it. Microsoft must close vb because they can,t give good markete to vb. Due to this reasons vb only developers are still poor in markete. They can switch to c# easly but their hearts shall always stick with vb. I know many languages like vb,c#,java,asp.net,php,mysql,sql etc but my heart always stick with vb. When i code in other language except vb then i always think to do that task in vb also. I love vb but what should i do while markete don,t have demand of vb?
-
Afraid so - Linq works by creating anonymous types which are specific to the query - so if you don't have a "define this from context" variable type it can't do things like this:
var v = myCollection.Where(w => w.ID < 10).Select(s => new {ID = s.ID, Name = s.Name});
Because you can't declare
IEnumerable<WhatNameWillTheCompilerGiveThatDamnThing> v = ...
It only annoys me when people use it as a shortcut datatype:
var v = 123;
Or to be really annoying
var v = GetSomething(somethingElse);
because it may save you 5 seconds typing, but I'm going to have to hunt down the method declaration to try and work out the heck you are doing... :mad:
Bad command or file name. Bad, bad command! Sit! Stay! Staaaay...
Was I that far off the target? :confused:
Wrong is evil and must be defeated. - Jeff Ello
-
Appologize if this is childish question but i am in too much confusion. I learnt first language vb6.0 in 2008 then i was student later and i continue it many years then 2 years ago i shifted to vb.net but in markete there is demand of c#. Many peoples told that c# is better than vb.net that,s why there is no value of vb.net in markete. I still can,t find any job to work in vb.net while i know vb well. Then i learnt C++ and i learnt it well and then i moved to c# and now i can code in c#. But problem is that i can,t code in c# same as in vb.net. I mean i always prefer vb. In vb i can solve any problem. but in c# i have to search from start and i don,t know why i like vb.net too much. In other words i don,t want to leave vb but markete always force to work in c# and foget vb. If vb is too bad in markete then why microsoft still supports it. Microsoft must close vb because they can,t give good markete to vb. Due to this reasons vb only developers are still poor in markete. They can switch to c# easly but their hearts shall always stick with vb. I know many languages like vb,c#,java,asp.net,php,mysql,sql etc but my heart always stick with vb. When i code in other language except vb then i always think to do that task in vb also. I love vb but what should i do while markete don,t have demand of vb?
I don't understand this. VB.NET is virtually intrinsically the same as C#, just in a C-style syntax rather than a BASIC-style one. The main difference is that function calls & signature definitions are encased in parentheses, and code blocks, including function & class blocks and namespaces, are encased in squiggly brackets {}. Once you incorporate this, there isn't a whole lot more to learn.
-
Anything you can do in C# you can do in VB. But...it doesn't work the other way round: and for that I'm truly glad. VB is a very old language which was designed to be used by non-programmers, and it retains some of that to this day. Most of the stuff you can do in VB that you can't in C# improves the quality of code and the ease of maintenance. String typing rather than weak typing is the major plus here, but any language which retains "On Error Resume Next" should be recycled as firelighters... X|
Bad command or file name. Bad, bad command! Sit! Stay! Staaaay...
OriginalGriff wrote:
Anything you can do in C# you can do in VB.
Events based on delegates with non-void returns? :-D (My personal favorite.)