Migrating from VB2010 App to VB2017 (Didn't Work!) RRS feed

  • Question

  • I wrote an app in VB6 that I wanted to use in VB2010.  Okay, used VB2008 to migrate up, then used VB2008 to migrate to VB2010.  My computer crashed, so I thought I would start using VB2017, thinking the VB2010 app could easily be modified to work in VB2017.  Well, it gives me a "Not able to load/migrate/ whatever".  Do I need another VB to do the intermediate migration?   Thanks.
    Tuesday, April 3, 2018 1:01 AM

All replies

  • Hi

    So what was the last working version running on?

    Regards Les, Livingston, Scotland

    Tuesday, April 3, 2018 1:05 AM
  • I have not done much conversion of unmanaged VB to managed VB but when I did I got the impression it would be easier if I returned to the unmanaged version and made some fixes there and tried again then the automatic conversion done by VS would have fewer problems.

    Have you tried using VS 2017 to do the conversion from VB 6? Or did you convert to VB.Net using VS 2008 or VS 2010? Are you sure it is saying it is unable to do the entire conversion? It is probably saying there is something specific it can't convert. You need to describe what that is, with relevant source code and the exact error message. The question you posted is about as useful as a rant with no useful information to solve the problem.

    Sam Hobbs

    Tuesday, April 3, 2018 1:16 AM
  • Do I need another VB to do the intermediate migration?   Thanks.

    IMO, you need to start from scratch that is reproduce the functionality that is in VB6 and make it work with a new project or projects in VB.NET, using VS2017.  

    Tuesday, April 3, 2018 5:35 AM
  • Hello,

    The main things that can break a migration are typically one or more controls that have no direct counterpart from VB6 in Visual Studio. You could make a backup of your VB6 project, look at controls in the VB6 project and if there are controls that are not standard get rid of them before the conversion and try again. This may be possible but no guarantees.

    Another option is to move as much code as possible from forms into code modules that don’t call any third party controls, do the conversion again in VS2008. At this point if the conversion is good stop there and live with what you have.

    The harder option to swallow is tossing out the idea of conversion and start a new solution in VS2017. You have the VB6 logic to refer to (thinking it has sound logic) but when moving away from VB6 you will find that somethings need more code than in VB6, this mostly is when working with databases e.g. RecordSets don’t exists but instead there are actually a handful of choices to choose from.

    Note that the default settings, Option Strict is Off, you can start with this but better to start with Option Strict On. This can be a long topic in itself so I suggest reading up on this.

    Learn to write the majority of code outside of forms as forms should be lightweight, working with data should be done in data classes.

    So you have options, which direct to go is dependent on time constraints and time to get up to speed with .NET coding.

    If you do the new .NET solution and run into issues ask questions, one at a time.

    Please remember to mark the replies as answers if they help and unmark them if they provide no help, this will help others who are looking for solutions to the same or similar problem. Contact via my Twitter (Karen Payne) or Facebook (Karen Payne) via my MSDN profile but will not answer coding question on either.
    VB Forums - moderator
    profile for Karen Payne on Stack Exchange, a network of free, community-driven Q&A sites

    Tuesday, April 3, 2018 9:30 AM
  • You need to be more specific with respect to the errors or we probably won't be able to help. Could you post the exact error message?

    Paul ~~~~ Microsoft MVP (Visual Basic)

    Tuesday, April 3, 2018 11:50 AM
  • John, 

    Your 2010 version would need normally not any change in code to run in version in VS 2017 (VB15)

    Probably the path is wrong. First try to open it by clicking on its .vbproj file. 

    If that does not go try than to look in the .sln file and then the .vbproj file what can be wrong.

    You can do that with notepad.


    Tuesday, April 3, 2018 12:20 PM