Skip to content

Blog

VS Versions Support Added to gmStudio

Update: We added support for VS2013 in the March 2014 Release of gmStudio.
Update: We added support for VS2015 in the June 2016 Release of gmStudio.
Update: We added support for VS2017 in the February 2018 Release of gmStudio.

and VS2019 and VS2022

That seems to be the name of the game in software development. Our customers need new features in their apps and we developers want new tools, and new techniques to build them. We are all just trying to keep up, stay current, keep that edge.

Microsoft is happy to keep moving the target too. .NET is arguably the fastest moving platform in the software tools market at the moment. The major milestones of .NET development evolution are the major releases of Visual Studio tabulated below (source):

Product nameCodenameInternal

version
Supported .NET

Framework versions
Release date
Visual StudioN/A4.0N/AApril 1995
Visual Studio 97Boston5.0N/AFebruary 1997
Visual Studio 6.0Aspen6.0N/AJune 1998
Visual Studio .NET (2002)Rainier7.01.0February 13, 2002
Visual Studio .NET 2003Everett7.11.1April 24, 2003
Visual Studio 2005Whidbey8.02.0, 3.0November 7, 2005
Visual Studio 2008Orcas9.02.0, 3.0, 3.5November 19, 2007
Visual Studio 2010Dev10/Rosario10.02.0, 3.0, 3.5, 4.0April 12, 2010
Visual Studio 2012Dev1111.02.0, 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2September 12, 2012
Visual Studio 2013Dev1212.02.0, 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2October 17, 2013


So … onward we go!

We started work on gmStudio in 2004 with VS2003 and .NET 1.1. Now we support rewriting VB6/ASP/COM code for VS2005, VS2008, and VS2010 although it has been a while since anyone showed interest in anything older than VS2008 and VS2010 is the default. With the release of a major service pack for VS2012, and VS2013 already in beta, its well past time to add support for VS2012. I want to use this blog post to walk through the addition of VS2012 support to gmStudio. I will describe some of the conventions and configuration features that allow gmStudio to target and integrate with different VS versions. The tasks in this small maintenance effort are as follows:

  1. Prepare to do the work.
  2. Analyze the significant differences between VS2012 and other VS versions
  3. Implement the changes

Preparation is downloading and installing VS2012 and checking it out. I downloaded the 1.5GB ISO for VS2012 Premium ran the install. All of that took a couple hours, but other than a couple restarts, it was smooth sailing. Looking at the VS2012 UI and… hmm … I think its called Metro right? Functionally everything seems to be there, and more, but it reminds me of the character-based IDE turbo-Pascal that I first did PC programming on back in 1984… very plain but now in high resolution. (Hey at least I didn’t compare it to DOS Basic). No problem, it works; and I bet it will grow on me.

I was able to rebuild the gmStudio projects (C#) in VS2012 with no issues. Our gmStudio-as-a-VS-Extension project did not load or upgrade - no surprise there; it is VS2010-specific. Also our plug-in will not load in VS2012; no surprise there either. Maybe I will do a separate blog post on bringing VSIX extension up to date.

The first thing I notice is that VS2012 is backward compatible with the VS2010 project files (i.e. csproj, vbproj) we generate for DLLs and EXEs. They open and work without asking to upgrade. Web Application projects on the other hand, automatically upgrade to VS2012 format. We will have to account for this minor matter when we translate web application projects.

Side-Bar: Multi-Version Environment

I installed VS2012 on a machine that also has VS2010 on it. I think this is typical for most people, but it does muddy the waters somewhat. In multi-version VS installations, opening a .NET project file (i.e., csproj, vbproj) can result in opening one of several VS versions. Microsoft decides which version by some means that involves looking for version specific solution file (.sln) in various locations and also looking at the application associated with .NET projects. Windows user’s can also associate project files with a small utility called the Visual Studio Version Selector.

The question is: what version of VS will be used to open the generated projects when we do a “shell open” operation from inside gmStudio? The short story seems to be: if you have Visual Studio Version Selector associated with .NET project files and If there is a VS2010 sln file in the same folder as your csproj, then VS2010 is used, otherwise it’s VS2012.

Updating gmStudio to support VS2012 is a matter of changing the UI on the migration project setup form and the user default form.

Updating the docs is also pretty mundane. We use a Wiki for the gmStudio User Guide, so the update is quick and easy. Gotta love a wiki…

gmStudio has a .NET build operation that tries to compile the generated csproj/vbproj file. This operation runs MSBuild as a shelled process. Before we can run MSBuild executable, we execute SetEnv.cmd. This is a command script distributed with gmStudio to setup the environment based on the desired VS version. SetEnv.cmd updated to support VS2012 is listed below.

Terminal window
@echo off
:: default to VS2010 if not specified.
if [%1]==[] set vssetup="%VS100COMNTOOLS%vsvars32.bat"
if [%1]==[VS2003] set vssetup="%VS71COMNTOOLS%vsvars32.bat"
if [%1]==[VS2005] set vssetup="%VS80COMNTOOLS%vsvars32.bat"
if [%1]==[VS2008] set vssetup="%VS90COMNTOOLS%vsvars32.bat"
if [%1]==[VS2010] set vssetup="%VS100COMNTOOLS%vsvars32.bat"
if [%1]==[VS2012] set vssetup="%VS110COMNTOOLS%vsvars32.bat"
:: If you do not have VisualStudio installed, and only the SDK, you will
:: need to use something like the following command depending on the target
:: framework SDK installation.
:: if [%1]==[VS2008] set vssetup="C:\Program Files\Microsoft.NET\SDK\v2.0\Bin\sdkvars.bat"
if not exist %vssetup% goto err
CALL %vssetup%
goto end
:err
echo %vssetup% NOT FOUND
echo Unable to setup .NET Framework SDK command line tools.
echo See %0.
exit /b 1
:end

We rarely use interop for migrations, opting instead to configure the tool to replace COM dependencies with .NET classes. However, if you decide to use interop in your upgraded project, gmStudio can help you produce interop assemblies. The feature works as follows: First gmStudio generates a csproj file that uses MSBuild tlbimport conventions to references the COM binaries referenced in your VB6/ASP code. Then gmStudio runs a batch build of this csproj. The .NET SDK tools do the actual interop assembly generation. The csproj file is tool version and .NET framework version dependent and these should be consistent with the interop assemblies.

VS2005: tool\framework Version = "2.0, v2.0"
VS2008: tool\framework Version = "2.0, v3.5"
VS2010: tool\framework Version = "4.0, v4.0"
VS2012: tool\framework Version = "4.0, v4.5"
...

At present these defaults are hard coded in gmStudio. This logic was modified to support VS2012.

For standard DLL and Exe projects, there are no required changes: you can open and build VS2010 files in VS2012 as-is. However, when the user selects VS2012, I want to default to Framework 4.5. This requires a small change to the a system configuration script called AuthorText.gmsl. The change is made in a function called Project_Preamble. A similar change is needed in function called StartNewcProject which is used when generating stub projects.

void Project_Preamble(string first)
{...
if(Select.DevEnv == "VS2008")
{...
}
else if(Select.DevEnv == "VS2010")
{...
}
else if(Select.DevEnv == "VS2012")
{
#TextStart
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" ToolsVersion="4.0">
<PropertyGroup>
<ProjectType>Local</ProjectType>
<TargetFrameworkVersion>v4.5</TargetFrameworkVersion>
#TextEnd
}
...

As mentioned above, web application projects are different in VS2010 and VS2012.

Opening a VS2010 web application project file in VS2012 will invoke a conversion process and display a conversion log:

Opening a VS2012 web project in VS2010 and will get you nothing but an error message about incompatibility.

I created new empty ASP.NET web application projects with both versions and compared them side-by-side. Most of the differences are MSBuild tool and targets. In any event, I made all differences conditional on DevEnv in AuthorText.gmsl. I am doing all this on a Win7 64 machine. There is chance it will not work on Windows versions.

There are two changes that result from setting DevEnv=“VS2012” in your migration project. First, the TargetFrameworkVersion=4.5. Second, there are some changes in the CSC command line string used by MSBiuld. Recall we modified SetEnv.cmd to call “%VS110COMNTOOLS%vsvars32.bat” which sets the environment to use the .NET build configuration installed with VS2012. There were a few changes in the build configuration. Most of the changes were Framework v4.0 to v4.5 related as expected. The other two changes relate to the highentropy flag and the subsystem flag.

  • highentropyrelates to the randomizing the layout of memory and relates to security. Security is good.
  • subsystem:6.00 means the application requires Windows Vista or higher. That is probably a valid assumption since we are also requiring Framework v4.5

These compiler settings are defaults chosen by Microsoft.

Improve your ROI for Modernization

A couple weeks ago, I attended a webinar by Steve McConnell, CEO of Construx. Steve is a top author and speaker on software development practices.

The title of the webinar was “The Business Case for Better Software Practices”. It made a bold assertion:

Improved Software Practices are Business’s Last Great Frontier
Aka “There’s gold in them thar hills!

As far as I was concerned, Steve was preaching to the choir, I have seen both sides and I know how much process matters. In my prior role, I helped overhaul the SCM processes for an enterprise IT organization and those improvements increased work capacity and productivity by about 300%.

A couple things about Steve’s presentation really resonated with me:

  • The data shows that software development (SD) process improvements result in big productivity improvements (a lot bigger than one might think).
  • From the Agile Manifesto: Individuals and interactions over processes and tools.

As evidence of the first point, Steve presented SD process improvement ROI results from many organizations and summarized them in this slide: ROI_for_best_practices.png

Steve’s presentation went on to stress how building staff capability is critical to implementing improved software processes. This fact is known by anyone who has worked with SD teams for a while: the people and how they work together matters - a lot. Ultimately, process improvements require people to correctly and consistently use new skills in doing their work. While new tools and technologies facilitate advanced SD processes, the ability of people to use those new tools and technologies is essential.

Taken together, these two matters are very interesting to me as a software modernization evangelist. Many of our prospective customers are struggling to make a sound business case for upgrading their software assets. They struggle because the sponsor views the upgrade as a zero-feature release that does not help the bottom line. However, now we have a considerable body of data that shows SD process improvements can have a great ROI for the organization. Furthermore, moving your system and your people to a contemporary platform is a prerequisite for improving your SD processes. Two specific forces are at work:

  • Developing software using contemporary tools and languages will help you recruit and retain people who are most motivated to build their capabilities.
    Ask yourself this question: Can you successfully recruit and retain highly motivated and capable IT professionals if your software is maintained in VB6 or ASP classic?
  • Developing software using contemporary tools and languages positions you to take advantage of best practices. In the vast majority of cases, these best practices are designed for and around the newer tools and languages:
    Ask yourself this question: Are the latest SD tools, techniques, books, and articles designed for VB6 and ASP classic or for more contemporary platforms like .NET?

If you agree that people are important, you need to set the stage to attract them to your organization and ultimately that means moving your legacy systems into the present.

So, in summary, if you are struggling to make a compelling business case for a large scale software upgrade project, consider repositioning the upgrade as part of a more comprehensive SD uplift including staff training and process improvements. The improved productivity can be the “carrot” to go along with this “stick” business case outlined here.

I trust a lot of readers out there will read this and say: Really? It’s hard enough to make the case for these type of things by themselves; there is no way I can make the case for both at once. I admit, this is a valid objection, I have been there and I know we both appreciate that making process changes in the development organization is hard and getting funds to pay for changes in the development organization is really hard. I am not saying it will be easy; but I am saying it will be easier if you can offer increased productivity and quicker delivery as part of the answer to the question “What’s in it for me?”

Thanks go to Steve McConnell and Construx for permission to reproduce material from the webinar.

gmStudio Release News: 13, February 2018

New gmStudio Case Studies and Testimonials

Section titled “New gmStudio Case Studies and Testimonials”

A recent customer allowed us to publish a brief description of their ASP/COM upgrade project and their testimonial of success with gmStudio. Learn how a small team accelerated their ASP site upgrade effort with the help of gmStudio. Read the article

gmBasic is a powerful code processor that reads, interprets, and rewrites VB6/ASP/COM systems as .NET (C# or VB.NET). We are always improving gmBasic to make it more robust and flexible and so that it produces cleaner, more correct results. This distribution, Version 30.63, includes several enhancements:

  • Prevents authoring duplicate members in COM stub classes when a coclass implements same-named members for multiple interfaces
  • Improves accuracy of Reference Report for explicit calls to user-defined event handlers
  • Improves upgrading the Select Case Statement
  • Begins work on a .NET API for developing custom VB6/ASP/COM upgrade solutions

gmStudio: Upgrade Solution Development Environment Update

Section titled “gmStudio: Upgrade Solution Development Environment Update”

Powered by gmBasic, gmStudio is a development environment for creating high-performance, custom VB6/ASP/COM to .NET upgrade solutions. We are always adding functionality to gmStudio and making it easier to use. This distribution includes several enhancements:

  • Adds support for using VS2017 IDE and the latest MSBuild
  • Adds support for setting .NET Framework Version using a registry command; for example:
<Registry type="VSConfiguration" source="FrameworkVersion" target="v4.0.0" />
  • Improves Task Filter performance
  • Adds Filter to Selection operation to the task list context menu
  • Improves Global Stubs Report to create a build script for compiling a COM Stub Framework
  • Adds Copy to Search operation to copy selected text to the Search Panel
  • Improves .NET Code Scan when searching for multiple pattern strings
  • Improves support for recognizing Custom Translation scripts
  • Improves accuracy of late-bound dependencies reported in the Source References Report
  • Improves gmStudio Installer to meet all Windows 10 Desktop Product Certification Requirements
  • Adds Support for UI Color Themes even if they are not installed with Visual Studio
  • Improves accuracy of containing member reported in Source Scan Report
  • Improves handling of comments when searchingUser files or Custom files

gmStudio ships with a collection of sample upgrade rules that can be used to add custom features to your upgrade solution. These XML documents and gmSL scripts are distributed as source that you may modify to fit your unique requirements. The sample rules were updated to reflect the latest product improvements and conventions.

  • Improves GlobalStubs.xml Script used to generate a COM stub framework
  • Improves GlobalStubs.cmd Script used to build a COM stub framework
  • Improves the Search Reporting templates

Great Migrations publishes a number of sample VB6/ASP upgrade solutions to illustrate the capabilities of gmStudio. The sample upgrade solutions were updated to reflect the latest product improvements and conventions.

  • Adds another WPF upgrade sample for the Calculator application (both C# and VB.NET)

Modernization Podcast Video Series Episode 3: Translation Myth Busters

Here is our third episode in a series of Podcast videos covering software modernization topics. This episode, Translation Myth Busters, takes on the question: should we Convert or Rewrite and challenges common misconceptions about the role and value of using legacy code and translation tools as part of a modernization strategy.

gmStudio Release News: Wednesday, 03-December-2025

Here is our third episode in a series of Podcast videos covering software modernization topics. This episode, Translation Mythbusters, takes on the question: should we Convert or Rewrite and challenges common misconceptions about the role and value of using legacy code and translation tools as part of a modernization strategy. Watch and listen here.

gmBasic is a computer language processor that reads, interprets, and rewrites VB6/ASP/COM systems for the .NET platform (using C# or VB.NET ). Based on feedback from our clients and real-world modernization projects, we continuously improve gmBasic to help developers produce cleaner, more correct results and to successfully manage and complete large-scale upgrade projects. Most recently, this includes enhancements relating to the work of upgrading a large VB6/ASP/COM/.NET payment processing application comprising 700 active pages backed by a 50K LOC VB6 service component library. The distribution, Version 50.27, includes several other important additions and improvements:

  • Adds support for recognizing and translating symbols declared in server-side Javascript (JScript) in ASP to C# or VB.NET
  • Adds a new FindDynamics command that may be used to assist with migrating late-bound object.member references to custom interfaces rather than using dynamic casts
  • Improves Form migrations so that DefInstance support is authored only for forms, MDI forms, and other Designer-based types that need it
  • Adds Migrate DefInstance=on|off to allow explicitly adding DefInstance support for a form when the requirement is not automatically detected
  • Improves migration of complex error handling/goto sequences to try-catch
  • Improves detecting the need to retain weak typing for variant when a variant parameter is assigned to an enum
  • Improves handling statements that invoke a default member in an object instantiation statement (e.g., Set obj = (new Class)(args))
  • Improves migration of Array function to string[] when the arguments to Array are a mixed set of types
  • Improves the migration of VB6 Line control to gmRTL.GUI.LineControl
  • Improves migration of string variable assigned to a void method
  • Improves translation of huge numeric literals (longlong quantities)
  • Improves translating VBScript With blocks in ASP code
  • Improves translating ASP sites having multiple same-named VBScript classes
  • Improves migration of conditional expressions comparing variant to empty string
  • Improves handling files with UTF-8 encoding and BOM
  • Improves logic to automatically increase code storage space when needed
  • Improves migration of ZOrder statements
  • Improves migration of complex conditionals involving integers and relational operations
  • Improves handling foreign class references
  • Improves support for Response.LCID in ASP translations
  • Improves authoring COM interface descriptions for read-only properties
  • Improves migration of intrinsic controls so that the property defaults more closely follow VS designer conventions

gmStudio: Upgrade Solution Development Environment

Section titled “gmStudio: Upgrade Solution Development Environment”

Powered by gmBasic, gmStudio is a platform for analyzing code and developing custom VB6/ASP/COM-to-.NET upgrade solutions. We continuously add functionality to gmStudio and make it easier to use. This distribution includes several enhancements:

  • Improves Validate Source operation to allow for upgrade tasks with no translation script

gmAPI: A .NET API for Developing Advanced Upgrade Solutions

Section titled “gmAPI: A .NET API for Developing Advanced Upgrade Solutions”

gmAPI is a .NET API for automating our upgrade engine and accessing the semantic models produced by our unique linguistic compilation technology. gmAPI also includes classes for managing complex upgrade rules and integrating external migration tools with gmStudio. We maintain and improve gmAPI and related components to keep them in sync with the platform and to add new features. gmAPI is central to our platform and gmAPI dlls are used to implement several advanced features: analytics reports, shared files consolidation, custom coding style, support framework generation, migration to WPF, and more.

The gmStudio platform includes advanced reporting services that allow you to gather extremely detailed information about your legacy system. The advanced reports include Symbol Tables, Symbol References, Symbol Definitions, Model Audits, and more. We maintain and enhance these reporting services to keep them in sync with the model schema and to add new features. See Semantic Reports for more information.

gmStudio ships with a collection of sample upgrade rules that can be used to add custom features to your upgrade solution. These XML documents and gmSL scripts are distributed as source code that you may modify to fit your unique requirements. The sample rules have been updated to reflect the latest product improvements and conventions. See also additions and changes in the gmStudio Extensions Repository.

  • Tabctl32.ocx.Wrapper.Transform.gmsl: Updated TabControl migration to be compatible with LineControl migration

gmRTL is a sample runtime library that contains classes allowing for more maintainable translations. We continuously improve this framework through real-world project work. Learn more about gmRTL here.

Great Migrations publishes several sample VB6/ASP upgrade solutions that illustrate various upgrade features. The sample upgrade solutions and results have been updated to reflect the latest product improvements and conventions. Learn about the Samples here.

  • Improves FMStocks samples to demonstrate just-in-time GlobalSettings integration

Great Migrations publishes FAQ articles and other information to help teams learn and use gmStudio. The following articles were added or updated since the last product update: