MFVSSW variable

 I see this can be used to 'modernize' dialog screens using unmanaged COBOL under Visual Studio.  Can it be used in a development environment?  It says to set the MFVSSW environment variable to "/c /f" , but where is this variable?  In Visual Studio?  Environmental variables under System Properties?  Is there something else we  need to get this to work?


Fran D.

  • Fran,

    There are various different ways that this can be done.

    You could set the variable at system level, or you could open a Command prompt, set the variable and then launch the Visual Studio executable, devenv.exe, or the application itself from the command prompt and it would be picked up.

    Alternatively, in Visual Studio, select the project for your executable that uses Dialog System, right click and select Add New Item. In the dialog box choose Application Configuration File. Once that has been added to the project double-click the item to display the dialog box which allows you to edit its content and you should see an Environment tab where you can add the MFVSSW variable. Once you have set the value it will be used when your application is run, regardless of whether or not you launched the application from Visual Studio.

    The /c (new style controls) and /f (new style fonts) options are independent of one another so you can set either or both.

    Another option is that the new style controls can be enabled without using an environment variable by specifying a resource to be linked into the executable. That is done by using the Add New Item dialog as mentioned previously but selecting Application Manifest. The manifest information gets linked into the executable when the project is built, and enables the new style controls for the entire application including any 3rd party controls you may be using.

    I hope that helps.