-
Tips for moving from VB6 to VB.NET [new info added 10-19-05]
i found this article on the MSDN website:
http://msdn.microsoft.com/library/de...ngtodotnet.asp
i thought it might be useful for anyone moving from vb6 to .NET or anyone who wants to learn about the basics of .NET
EDIT: This free book from microsoft also gives assistance for moving from vb6 to .NET
-
Re: Tips for moving from VB6 to VB.NET
I slightly changed the subject of the thread and made this a sticky. We will keep it near the top for a little while to help anyone that is migrating over..
-
Re: Tips for moving from VB6 to VB.NET
I suppose I can contribute to this thread since I am doing a 40,000 line VB6 conversion to .NET. I (highly) recommend biting the bullet and just doing a rewrite. There have been some good things about converting (like not having to rewrite some code), but in the long run...my feeling is that a full rewrite would have been better.
-
Re: Tips for moving from VB6 to VB.NET
Just wanted to mention dan appleman has a great book on moving from vb6 to vb.net.
You can search for authors via amazon and his book should come up.
-
Re: Tips for moving from VB6 to VB.NET
One tip I suggest is...
.NET allows use to use old VB6 code in .NET by using the Microsoft.VisualBasic import declaration...
I suggest that you use true "VB code" using the frameworks VB syntx.
What I mean is... use the .NET framework's visual basic commands and not the VB6 commands. Convert all your VB6 code to true .NET framework code.
It will save you headaches in the future.
-
Re: Tips for moving from VB6 to VB.NET
Quote:
Originally Posted by epixelman
One tip I suggest is...
.NET allows use to use old VB6 code in .NET by using the Microsoft.VisualBasic import declaration...
I suggest that you use true "VB code" using the frameworks VB syntx.
What I mean is... use the .NET framework's visual basic commands and not the VB6 commands. Convert all your VB6 code to true .NET framework code.
It will save you headaches in the future.
which means remove the Microsoft.VisualBasic import that a new VB app automatically adds for you in the IDE
-
Re: Tips for moving from VB6 to VB.NET
Quote:
Originally Posted by tr333
I think it was you who recently posted a link to SharpDevelop. As I currently can't afford the bucks or euros to go for .net I thought your suggestion was an interesting one. Now my question is, is the language syntax of .net the same as that of SharpDevelop, or will I have to start from scratch whenever I get .net even if I have acquired a basic yet fairly acceptable knowledge of SD?
-
Re: Tips for moving from VB6 to VB.NET
You know you can get the basic version of VB.NET 2003 for 100 bucks (US)
http://msdn.microsoft.com/howtobuy/vbasic/default.aspx
also you can download the .net 2005 beta for free and use that until you have a good grasp of the language and then upgrade to a pay version of 2005 (which would be out by then)
-
Re: Tips for moving from VB6 to VB.NET
SharpDevelop is just another IDE for developing software in .NET, like visual studio. so there would be no differences to the actual code/syntax.
you could even code in notepad if you were feeling really hardcore...
-
Re: Tips for moving from VB6 to VB.NET
Quote:
Originally Posted by tr333
you could even code in notepad if you were feeling really hardcore...
ahhh just like my HTML :bigyello:
-
Re: Tips for moving from VB6 to VB.NET
Quote:
Originally Posted by tr333
SharpDevelop is just another IDE for developing software in .NET, like visual studio. so there would be no differences to the actual code/syntax.
you could even code in notepad if you were feeling really hardcore...
Great. Now, what are the features I am exactly missing from .net? I mean, going from VB6 to SharpDevelop, would that be a step down?
-
Re: Tips for moving from VB6 to VB.NET
Quote:
Originally Posted by krtxmrtz
Great. Now, what are the features I am exactly missing from .net? I mean, going from VB6 to SharpDevelop, would that be a step down?
from an IDE perspective possibly since the Microsoft IDE is by far the best....(of course this is my opinion)
but from a programming standpoint NO its not, because you would be creating .net apps and not vb6 apps
-
Re: Tips for moving from VB6 to VB.NET
Understand OOP!!!!!
http://www.codeproject.com/useritems/OOPS_In_VBNET.asp
ALWAYS USE:
Option Strict On ' Requires Explicit Type Conversions eg. CType, DirectCast, ect.
Option Explicit On ' Requires Explicit Typing, Dim x as String, NEVER leave this off...
Comment Your Code
-
Re: Tips for moving from VB6 to VB.NET
I tried SharpDevelop and found it lacking quite a few features.
It does use the .net framework syntx... so going from SD to .NET codewise won't be a problem.
But SD has no debugger.
Doesn't handle OCX or 3rd party .NET controls very well.
Doesn't do mobile very well
and no ASP controls or window forms.
Is only on version 1.0.3.
Although it is a good start for beginners.... if you are serious about using .NET, then get VS 2003 or 2005 (when it comes out)
If you are a student, you can get Academic for under a $100...
-
Re: Tips for moving from VB6 to VB.NET
I haven't really played with #Develop but
and no ASP controls or window forms.
The Windows forms controls are in the .Net Framework System.Windows.Forms
The asp.net controls are in the .Net Framework System.Web.UI
Is only on version 1.0.3.
There have only been two versions of Visual Studio .Net (and this does not much meaning anyway)
-
Re: Tips for moving from VB6 to VB.NET
<ABX...
Although the ASP is in the framework... SD (SharpeDevelop) has not implemented them to use on the WinForms.... meaning that when you put code on the form it doesn't automatically write the needed code. They only have auto code creation for C# and VB.
VS may be on it's second version, but is way..way far more advanced.
SD is missing alot of functions. Not to mention that is is unstable.
mendhak said it best concerning SD...
"Pro's... it's free....... Con's.... it's free."
You get what you pay for with SD. (oh which is nothing)
.
-
Re: Tips for moving from VB6 to VB.NET
Quote:
Originally Posted by epixelman
<ABX...
Although the ASP is in the framework... SD (SharpeDevelop) has not implemented them to use on the WinForms.... meaning that when you put code on the form it doesn't automatically write the needed code. They only have auto code creation for C# and VB.
VS may be on it's second version, but is way..way far more advanced.
SD is missing alot of functions. Not to mention that is is unstable.
mendhak said it best concerning SD...
"Pro's... it's free....... Con's.... it's free."
You get what you pay for with SD. (oh which is nothing)
.
Just because it isnt automatically done for you doesnt mean it doesnt work. you should be able to copy and paste the code from an form created in visual studio .Net and it should look the same.
-
Re: Tips for moving from VB6 to VB.NET
Can you run both Visual Studio.Net and VB.net 2005 (Beta) on the same machine without any problems. I'm thinking about doing more with VB.Net but don't want to break my present version while trying the Beta.
Thanks,
Michael
-
Re: Tips for moving from VB6 to VB.NET
Quote:
Originally Posted by Rev. Michael L. Burns
Can you run both Visual Studio.Net and VB.net 2005 (Beta) on the same machine without any problems. I'm thinking about doing more with VB.Net but don't want to break my present version while trying the Beta.
Thanks,
Michael
Yes, you can install all different versions along side eachother, which includes VB6, VB.NET 2002, 2003, and 2005 beta
-
Re: Tips for moving from VB6 to VB.NET
I dont recommend installing a beta version along side of another production version since M$ is famous for making the
beta versions not upgradeable nor uninstallable.
If you have a test system available (one that you can reformat) I would highly suggest that you install the
beta version on it instead, unless you dont mind having to reformat your production system in order to perform
an upgrade. ;)
-
Re: Tips for moving from VB6 to VB.NET
Rob, did you actually experience a problem uninstalling the beta 05? I have not tried to, but I don't see why it would be a problem. Both the 2.0 beta framework, and the 2005 beta IDE are listed in the add/remove program list. And I don't see why there should be any issues. 2005 is really just enhancements to the IDE and framework, which means the basic concepts for installing/uninstalling stem from 2003 (which in turn came from 2002) I would hope the install/uninstall should be pretty standard by now...
-
Re: Tips for moving from VB6 to VB.NET
I had read that the 2002 and 2003 had these issues when they were in beta. I havent taken too much of a
look into the 2005 but I am just waiting for a RTM release before I install on my production system along side of
VB6 and 2003.
Has anyone tried uninstalling 2005 beta yet?
-
Re: Tips for moving from VB6 to VB.NET
IS .NET the new version of VB6 ya, or is it design for different application mainly networking?
-
Re: Tips for moving from VB6 to VB.NET
Quote:
Originally Posted by chris lynch
IS .NET the new version of VB6 ya, or is it design for different application mainly networking?
I would say that VB.Net is based on VB6, there are quite a few difference.
Networking has been completely restructured... No More Winsock control, you need to Use the System.Net.Sockets Classes. More complex but much more powerful.
-
Re: Tips for moving from VB6 to VB.NET
I think what chris meant was is the ".NET" in VB.NET because it is designed for networking, etc...
the .NET actually I think is more based on the concept of having a framework to run managed code versus having much to do with the internet or networking. Yes VB.NET can interact with the internet and networks worlds better than VB6, but it does just about everything worlds better than VB6
-
Re: Tips for moving from VB6 to VB.NET
SharpDevelop is a pile of cack imho. Buggy, ugly and VERY VERY slow to load and takes up scandalous resources. VS is 100 times better
-
Re: Tips for moving from VB6 to VB.NET
Im gettimg the feeling you can't use both VB and VB.Net :( installed on the same disk/machine/pc.
I want to keep coding in VB6 but want to dabble with VB.Net to check it out. Will probably use VS .Net 2003. So what will stuff up first and what is the work around? :D
-
Re: Tips for moving from VB6 to VB.NET
Quote:
Originally Posted by PALAEOLOGOS
Im gettimg the feeling you can't use both VB and VB.Net :( installed on the same disk/machine/pc.
I want to keep coding in VB6 but want to dabble with VB.Net to check it out. Will probably use VS .Net 2003. So what will stuff up first and what is the work around? :D
What workaround? VB6 and VB.Net Get along fine.
-
Re: Tips for moving from VB6 to VB.NET
Are you sure man? I have the disks and Im about to install on your advice..... I remember something to do with global OS environment variables and compilation and execution problems.......
If you are wrong I'm sending you the grumpiest smiley I can find. ;)
-
Re: Tips for moving from VB6 to VB.NET
The only time there was any problems with VB6 and VS.NET on the same machine was when VS2000 was still in beta. Since it's gone gold, it hasn't been an issue. We've got VB6 and VS.NET 2003 here on everyone's machines and narry a problem. I do knwo that it's recommended that VB6 be installed FIRST, then .NET installed second.
Tg
-
Re: Tips for moving from VB6 to VB.NET
yeah I also have not had a problem on any of the several machines I have IDEs installed on. On one machine I have VB6, 2002, 2003, and 2005 beta
-
Re: Tips for moving from VB6 to VB.NET
k.
Just pressed install. Be back to tell you how it goes :D
-
Re: Tips for moving from VB6 to VB.NET
I'm sure it will be fine. I felt the same when I first did a side-by-side install of VS6 and VS.NET 2003.
I have not had one issue yet after almost a year. :thumb:
-
Re: Tips for moving from VB6 to VB.NET
No longer a .Net virgin I feel my inocense has been stripped away.
Looks very good! I compiled and packaged some of my VB6 Apps to check what would happen and all is ok. I can't seem to find the Deployment Wizard for VB.Net does it have one?
-
1 Attachment(s)
Re: Tips for moving from VB6 to VB.NET
Quote:
Originally Posted by PALAEOLOGOS
No longer a .Net virgin I feel my inocense has been stripped away.
Looks very good! I compiled and packaged some of my VB6 Apps to check what would happen and all is ok. I can't seem to find the Deployment Wizard for VB.Net does it have one?
Setup wizard is now a project.
So you may find it in the new Projet windows
-
Re: Tips for moving from VB6 to VB.NET
See this thread for more info on .NET Setup.
Also, in the Application Forums FAQ there are a couple of articles on deploying a .NET app. ;)
-
Re: Tips for moving from VB6 to VB.NET
Quote:
Originally Posted by RobDog888
Has anyone tried uninstalling 2005 beta yet?
I did actually. I uninstalled the .NET 2.0 beta framework and the IDE completely
Working fine :D I even installed the .NET 1.1 framework and VS.NET 2003 after that so I would say it works well.
I think this is only in the beta of 2005 but I couldn't compile right :confused: It never produced a .exe and there was always this weird installation thing that I didnt like.
-
Re: Tips for moving from VB6 to VB.NET
I'm working on a program that I was originally doing in VB editor because I wanted to get a start on it while I waited for my VB2003.Net to come. I would like to somehow transfer this work from editor to .Net. Is there a way to do this? I have Window2000 Professional if that helps to understand what kind of editor I was using. I appreciate the help! Thanks!
-
Re: Tips for moving from VB6 to VB.NET
it doesn't explain at all what editor you were using. What was the editors name?
-
Re: Tips for moving from VB6 to VB.NET
I'm using the excel VB editor. sorry