-
Sep 1st, 2010, 06:45 PM
#1
Thread Starter
Addicted Member
Conversion From VB6
Hello everyone. I'm wanting to use a bit of code that someone pointed me to in a VB2010 application, however the code is in VB6. How would I go about converting this from VB6 to VB2010? I've personally never done a conversion of complete code like this, so help would be wonderful!
Here is the link:
http://www.vbforums.com/showthread.php?t=449751
-
Sep 1st, 2010, 07:00 PM
#2
Re: Conversion From VB6
VS 2008 comes with an upgrade wizard (just open the .vbp file). This wizard is no longer included as of VS 2010.
However, this is by no means automatic - you will need to research the pitfalls. Some preparation of the VB6 project is usually recommended and the adjustments required after the wizard finishes are not trivial.
-
Sep 1st, 2010, 07:04 PM
#3
Thread Starter
Addicted Member
Re: Conversion From VB6
Alright.. is there any kind of tool that will help me convert from VB6 to 2010? Or is there a guide placed somewhere?
-
Sep 1st, 2010, 07:26 PM
#4
Re: Conversion From VB6
VB9 (VS 2008) code will work unchanged in VB10 (VS 2010).
-
Sep 1st, 2010, 07:28 PM
#5
Thread Starter
Addicted Member
Re: Conversion From VB6
ah okay, so I will need to install VB2008 and run the wizard then?
-
Sep 2nd, 2010, 08:50 AM
#6
Re: Conversion From VB6
The wizard will do a bad job at best, unless the code is exceedingly trivial. If you search this forum on that subject, you will find that virtually everybody says the same thing: You are better off re-writing than converting.
The differences between VB6 and .NET are too great for a conversion tool to do a reasonably good job on all but the simplest code.
My usual boring signature: Nothing
-
Sep 2nd, 2010, 09:30 AM
#7
Re: Conversion From VB6
I tried ... ran into a number of problems... so I searched by the API name and .NET.... found this... it's in C#.. but it should be a LOT easier to convert from C#to VB than to try to upgrade the VB6 code to .NET.
http://social.msdn.microsoft.com/for...A-5FBE7A46B61A
-tg
-
Sep 2nd, 2010, 06:52 PM
#8
Thread Starter
Addicted Member
Re: Conversion From VB6
Thanks for all of your help so far!
I've had a look at the code, and obviously I need to include the wininet dll. However, for some reason, when I try to make a reference to wininet.dll, it gives me an error saying that it cannot add the reference. Is there maybe an alternative method, or a built in version of InternetSetOption()?
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
|