|
-
Jul 5th, 2010, 07:41 PM
#1
Thread Starter
PowerPoster
VB6, VB.Net, and VB 2010
OK, let's get it out on the table.
Is VB.Net just a go-between? Why not skip VB.Net completely and convert all "out-of-date, obsolete" VB6 code to VB 2010 and be done with it?
-
Jul 5th, 2010, 09:27 PM
#2
Re: VB6, VB.Net, and VB 2010
VB 2010 (which is vb.net 2010, or vb v10 if you go strictly by version #'s) runs on the .Net 4.0 Framework. So by coding in VB 2010, you're coding in .Net and not skipping it at all.
-
Jul 5th, 2010, 11:00 PM
#3
Re: VB6, VB.Net, and VB 2010
Furthermore, VS lets you choose which version of .Net Framework you want to target. So you can code in VS 2010 and still target .Net Framework v2.0, v3, v3.5 or v4
-
Jul 6th, 2010, 04:01 AM
#4
Re: VB6, VB.Net, and VB 2010
In terms of being a "go between", VB.Net (2002 to 2010+) has already lasted longer than VB 1 to 5 (1991 to 1997+), and is only a couple of years from reaching the point where it will have been "current" for longer than Classic VB was - and that is likely to happen before MS even release the next version, let alone think of moving on to something else.
-
Jul 6th, 2010, 05:01 AM
#5
Re: VB6, VB.Net, and VB 2010
Wait, VB2010 is not VB.NET anymore? Why didn't anyone tell me? That's great news. I've stopped distributing the .NET framework at once and told all my clients that they no longer need it.
-
Jul 6th, 2010, 06:41 AM
#6
Thread Starter
PowerPoster
Re: VB6, VB.Net, and VB 2010
Well, thanks for the clarifications. The price seems reasonable. What I was also wondering is whether there is another learning curve going between Vb.Net and VB 2010. The jump from VB6 to VB.Net was rather significant. Losing the Shape control and several useful DLLs I was using sank my ship also. So, I abandoned .Net and went back to VB6.
Are there going to be similar Gremlins and pitfalls awaiting when I start writing in VB 2010? Just curious. Nothing is more frustrating than moving into a new language and losing both power and flexibility--kind of like buying a new house and having to sell half your furniture and equipment.
-
Jul 6th, 2010, 06:48 AM
#7
Re: VB6, VB.Net, and VB 2010
Ok, in case you didn't get that, my last post was sarcastic.
VB2010 is just another name for VB.NET used in Visual Studio 2010. It is not a new language. There are a few small new features (such as not requiring the use of an underscore as a line continuation character) but you don't need to use them.
I'm sure you can just copy/paste your VB.NET (from VS2005 or VS2008) code into VS2010 and it will work flawlessly.
VB6 and VB.NET are two different languages.
VB2005, VB2008 and VB2010 (those aren't even official names I think) are merely new, updated versions of the same language.
-
Jul 6th, 2010, 06:57 AM
#8
Thread Starter
PowerPoster
Re: VB6, VB.Net, and VB 2010
Thanks, Nick. Beware of sarcastic posts. A few of us are short on IQ when it comes to software releases, including languages. 
What I can assume, therefore, is that the same shortcomings I ran into when moving code from VB6 to VB.Net are going to arise again. Guess I'll have to be prepared for that.
-
Jul 6th, 2010, 07:03 AM
#9
Re: VB6, VB.Net, and VB 2010
 Originally Posted by Code Doc
What I can assume, therefore, is that the same shortcomings I ran into when moving code from VB6 to VB.Net are going to arise again. Guess I'll have to be prepared for that. 
I have no idea how you came to this conclusion. Didn't I say literally:
I'm sure you can just copy/paste your VB.NET (from VS2005 or VS2008) code into VS2010 and it will work flawlessly.
If you have a VS2005 or VS2008 project, you can simply open it in VS2010 and it should be converted for you. The code will not be touched (as it doesn't need to be).
VB6 and VB.NET are two different languages and, apart from syntactic similarities, they are completely incomparable.
VB.NET in VS2005 and VB.NET in VS2010 however are the same language, except for the fact that VS2010 offers some new features. So VB.NET code in VS2005 should run just the same in VS2010. The opposite of course is not true; if you are using any of the new VS2010 VB language features you will not be able to copy/paste that code back to VS2005 (or VS2008) because those languages didn't support those features yet. But if you are converting from VS2005 or VS2008 to VS2010 then nothing needs to change.
Last edited by NickThissen; Jul 6th, 2010 at 07:07 AM.
-
Jul 6th, 2010, 08:33 AM
#10
Re: VB6, VB.Net, and VB 2010
Nick did you miss this: I abandoned .Net and went back to VB6. --- he'll be coming from VB6... not a previous .NET version.
Doc - as for losing power and flexibility ... it depends. I feel the opposite. With .NET I've had greater power and flexibility available to me. But then your needs are most likely different from mine. I'm beginning to think I'm one of the few that welcomed .NET with open arms in its early days. Sure it was tough nut to crack - it took me a long time to figure out ADO.NET - but once I did and got some of the basics... it's been easy to roll with the changes since - except the WPF WCF stuff... still struggle with that, but mostly because I don't use it day to day... but I at least have an inkling of the basics.
Having said that... yes, if you are using the shape control... you might run into issues. Depending on what you are doing with it, you'll need to find a thrid party control (I think there's something in the power pack ... but I'm not sure) or you'll need to learn a little bit of GDI to draw things yourself (during which you'll probably end up creating a library that you can reuse easily).
If you need some local help - drop me a line... I work mid-town near Turner Plaza. Also there's a local .NET User Group ... next meeting is July 29. http://www.funwith.net/
-tg
-
Jul 6th, 2010, 08:43 AM
#11
Re: VB6, VB.Net, and VB 2010
 Originally Posted by techgnome
Nick did you miss this: I abandoned .Net and went back to VB6. --- he'll be coming from VB6... not a previous .NET version.
I see. Well, my answer is still the same. There are hardly any differences between VB in VS2005 and VB in VS2010, except for some new features (which doesn't matter as you are looking for backward compatibility). So, it doesn't matter whether you upgrade from VB6 to VS2005 or from VB6 to VS2010. You will have exactly the same problems.
As for a shape control, do you need shapes that the user can move and resize (I'm not familiar with the VB6 shape control)? In that case, you can take a look at my 'Shape Editor' codebank thread. It's written in C#, but any converter should easily get it back to VB.NET, or you could just add the project to a new solution (you can combine VB.NET and C#.NET in the same solution if you have Visual Studio).
-
Jul 6th, 2010, 09:18 AM
#12
Re: VB6, VB.Net, and VB 2010
There's the .Net PowerPack you can install that has most of the shape controls from vb6. PowerPack shipped with VS 2008 and I believe VS 2010, so you've got it with you as if it's included with the .Net Framework. Just be sure the end users have it installed (mark it as a pre-req in your installer) when they install your app.
-
Jul 6th, 2010, 10:21 AM
#13
Re: VB6, VB.Net, and VB 2010
Gee, I'm using VS2010, and after reading this, I now understand why I am feeling out of shape.
My usual boring signature: Nothing
 
-
Jul 6th, 2010, 04:33 PM
#14
Thread Starter
PowerPoster
Re: VB6, VB.Net, and VB 2010
 Originally Posted by Shaggy Hiker
Gee, I'm using VS2010, and after reading this, I now understand why I am feeling out of shape.
A little humor never hurt any thread. Shaggy is a past master at it.
Here's a sample Pic of my Shape control work:

Yeah, I suppose I could have struggled with MS Chart to do the same, but it was much easier with the Shape control.
Another Active X control that I use is Resize OCX that probably is now available for .Net, but I haven't really investigated. I supply this mainly for visually impaired users. And, by now, my Tarma Installer program can handle .Net Apps. Tarma has one of the best tech support teams in the business.
So, yes, I guess I was lazy, but the timing was not ripe for me to leap into .Net back in 2004 or so. When you have thousands of code lines to work on, hundreds of hours of conversion work, and publication deadlines staring you in the face, you tend to be hesitant.
Last edited by Code Doc; Jul 7th, 2010 at 08:37 AM.
Doctor Ed
-
Jul 6th, 2010, 07:28 PM
#15
Re: VB6, VB.Net, and VB 2010
Now that I see that, I remember what you mean. I wrote a similar form in VB6. That shape stuff was a good way to draw odd bar charts and the like.
I am currently working on using GDI+ in .NET (at least I think I am, the terminology might be wrong). The capability to draw what you have in that example is certainly there, and it isn't difficult. Whether it is easier than it was in VB6, or harder, I cannot say, as it has been too many years since I worked in VB6.
However, I think you were right back in 2004, or so. Personally, I feel that .NET made a huge leap forward with VS2005 to the point that lots of common VB6 code constructs were replaced by something vastly better. In specific, I am refering to generic collections almost entirely replacing arrays. There were several other enhancements, and even more with framework 3.5 (VS2008 and on), but I think it was generic collections that really sold it to me.
My usual boring signature: Nothing
 
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|