Improve company productivity with a Business Account.Sign Up

x
?
Solved

opening VB 6 projects in .NET Studio?

Posted on 2004-10-27
8
Medium Priority
?
273 Views
Last Modified: 2010-05-02

I have been using  Visual Studio 6 for some time. I want to start using Visual Studio .NET 2003. At first I need to stay productive by using my existing VB 6 knowhow.
So I will want to access VB 6 projects with VB.NET 2003. Moreover, I will be continuing to write VB 6 projects from scratch.

I have heard that there are many differences between VB 6 and VB.NET. I.E. a bit of a learning curve. Is this true? Will I be a bit shocked by VB.NET's interface?
Also, will there be any compatability problems between my old VB 6 project's and the way VB.NET deals with them?

Thanks

C
0
Comment
Question by:cakester
  • 4
  • 2
  • 2
8 Comments
 
LVL 86

Expert Comment

by:Mike Tomlinson
ID: 12430417
You can have both VB6 and VB.Net on the same machine with no problems.  They don't interfere with each other in any way.

>> So I will want to access VB 6 projects with VB.NET 2003.

You can create a new VB.Net from a VB6 project using the upgrade wizard, but you cannot take projects back and forth between the two development environments.

>> I have heard that there are many differences between VB 6 and VB.NET. I.E. a bit of a learning curve. Is this true?

VB.Net is a fully object oriented language bringing it on par with other languages such as Java, C++ or C# (let the flame wars begin...) .  If you are comfortable with true object oriented programming then you won't have a problem, otherwise there may be some "growing pains" as you learn the VB.Net way.

>>  Will I be a bit shocked by VB.NET's interface?

The actual IDE isn't all that different from the IDE in VB6.  I will say though that the editor and intellisense abilities in VB.Net have been vastly improved over VB6.

>> Also, will there be any compatability problems between my old VB 6 project's and the way VB.NET deals with them?

The main complaints I see from VB6 to VB.Net converts are the lack of the Forms collection, lack of Control Arrays, lack of the AutoRedraw feature in PictureBoxes, and the loss of the Winsock control...but once you learn how to overcome these "deficiencies" using other techniques available to from the language and framework, you will never turn back.

Having said all that, I don't recommend using the Upgrade Wizard as you are better off recreating VB6 apps from scratch.  You will get valuable experience learning how to do things the proper VB.Net way.  Besides that, the upgrade wizard does things in its "own special way" and results in code you would never see in a pure VB.Net application.

Regards,

Idle_Mind
0
 

Author Comment

by:cakester
ID: 12430817


Idle_Mind,

What I meant with regards to using VB 6 projects in VB.NET: can I open VB 6 projects in VB.NET's Interface and use that said interface with all the commands, forms can language that I would be able to use under VB 6 itself? So, I would be working in kind of a VB 6 mode a bit like some Windows apps would work in a WIN16 mode.  I.E. no converting to VB.NET land.
I understand that I would be restricted to VB 6 commands etc etc?

What does IDE stand for, in this context?

>> you are better off recreating VB6 apps from scratch
Writing any application in a new language, from scratch; that  you don't know, could take a very long time...  Am I missing something here?

C
0
 
LVL 86

Accepted Solution

by:
Mike Tomlinson earned 750 total points
ID: 12430852
IDE = Integrated Design Environment (Visual Studio)

No, you cannot open a VB6 project in the VB.Net in a "VB6 only mode".  You have to convert it to a VB.Net project with the Upgrade Wizard.

>> Writing any application in a new language, from scratch; that  you don't know, could take a very long time...  Am I missing something here?

Your right...it may take awile.  The differences between VB6 and VB.Net are pretty significant though, and the code produced by the upgrade wizard often doesn't reflect how things would be done if the app were created from scratch in VB.Net.

I recommend you create a simple VB.Net app that with basic controls and play with them.  Then proceed to write the app from scratch.  Believe me, the code will be much better and you will learn more.

If you absolutely need the app in VB.Net now, then use the Upgrade Wizard but I don't see any benefit from it since the app will do the same thing.

~IM
0
Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

 
LVL 14

Expert Comment

by:Shiju Sasidharan
ID: 12430894
Hi Idle_Mind
i am quite surprised and happy with ur comment

>>You can create a new VB.Net from a VB6 project using the upgrade wizard, but you cannot take projects back and forth between the two development environments.

Can u pls tell how can we use this Upgrade Wizard?
is it come along with VB.Net ? or seperate application ?

regards

;-)
Shiju


0
 
LVL 86

Expert Comment

by:Mike Tomlinson
ID: 12433074
>> Can u pls tell how can we use this Upgrade Wizard?
is it come along with VB.Net ? or seperate application ?

The Upgrade Wizard comes with VB.Net.  To start it, simply click on "Open Project" on the Start Page (or File --> Open --> Project from the menu), and then navigate to the VB6 project file (*.vbp) you want to convert.

The Wizard will automatically start.  The default selections in the wizard should work in most cases.  When the wizard is done, the "Task List" window will have a list of areas in the code that didn't convert properly and will need further "manual conversion" (Not all commands in VB6 have a direct counterpart).  Comments will also be placed directly above lines of code that may have problems after conversion.

~IM
0
 
LVL 14

Expert Comment

by:Shiju Sasidharan
ID: 12436487
hi
Thanks Idle_Mind
i will try it out the method
thanks a lot
>>"manual conversion"
will it require lots of conversions if the VB project is big ?

;-)
Shiju
0
 
LVL 86

Expert Comment

by:Mike Tomlinson
ID: 12436511
>> will it require lots of conversions if the VB project is big ?

Sadly, the answer is Yes in most cases.

Let me know how the conversion goes and if I can help you fix any parts of it.

~IM
0
 

Author Comment

by:cakester
ID: 12450645
thanks for your help.

C
0

Featured Post

Get your problem seen by more experts

Be seen. Boost your question’s priority for more expert views and faster solutions

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Have you ever wanted to restrict the users input in a textbox to numbers, and while doing that make sure that they can't 'cheat' by pasting in non-numeric text? Of course you can do that with code you write yourself but it's tedious and error-prone …
You can of course define an array to hold data that is of a particular type like an array of Strings to hold customer names or an array of Doubles to hold customer sales, but what do you do if you want to coordinate that data? This article describes…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

608 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question