The Lounge is rated Safe For Work. If you're about to post something inappropriate for a shared office environment, then don't post it. No ads, no abuse, and no programming questions. Trolling, (political, climate, religious or whatever) will result in your account being removed.
Is the syntax of VB really so appalling that you refuse to work with it? I find that funny as it simply uses the alphabet which we read every day.
Other than the syntax it's .NET, so the same as C# (possibly with Option Strict set to Off, which is bad).
Automatically converting it won't make the code any better (but probably worse), you'll just have bad code that's written slightly different.
I'm so tired of this C# vs. VB.NET debate.
It's the same framework with (mostly ) the same options.
Do you really feel so much better because you write C# instead of VB?
Personally I've seen code in both C# and VB that makes you want to spoon your eyes out.
I'm not really bashing VB.Net (it is just the Syntax that is different), only really due to me not really being a basic programmer, I'm a hardware guy really I feel happier with C (or assembly!) as I can look at it and see quicker why it's not working where as with Basic I always have to read the code carefully, I was really only happy with basic at school on a BBC Master (to date me!). Really it is just speed with this this is 'pretty is nice, ugly works' time is critical!
believe me I know all about PID/VIDs and CDC device...we are old foes. I was just that this board didn't do that. It uses some Native means of sitting on the USB tree, as a HID compliant device rather than a CDC, hence my question about converting the project.
Well written and designed VB is fine so you may be pleasantly surprised when looking at the code.
I think it is just that because VB has become synonymous with bad coding that it common amongst us to assume that VB is a bad choice.
It's the same framework, Griff's suggestion of converting it to a DLL is a good one - I have done this myself and in my C# projects I use some code that was previously written in VB as converting it to C# would risk introducing errors.
“That which can be asserted without evidence, can be dismissed without evidence.”
Sanity has returned I have managed to find the DLL I think it uses and now it looks alot easier than I though! note to self 'when you can see trouble in the distance don't immediately yell for help, you might not need as much as you think!'
[I hope this doesn't cross the line of what I shouldn't post about here...]
I was just reminded of the oft-given advice that to improve your coding skills you should "read lots of code". This made me wonder: What code should I read? If I were a painting instructor, I would advise my students to study the masters: Michelangelo, VanGogh, Norman Rockwell, Bill Watterson. But what about coders?
What are some of the classic code-bases that every aspiring software developer should read at least once in his/her life? Alas, some of the best are doubtless locked up behind proprietary firewalls, but of the code that is publicly available, which programs would you suggest are worthy of studying or even emulating?
IMHO, the advice is misleading. I think the author meant you should try to learn from other people's code in the context of the work you're doing.
For example, if you've been tasked with fixing a SQL injection bug in a method (easy enough to do), look for other places in the codebase where this has been done and see if the developer implemented other safeguards (e.g. validating or auto-fixing parameter values).