Q. How can I modify a System gmSL routine?
A. A typical gmStudio translation is directed by several things:
The system metalanguage files and gmSL scripts are typically pre-compiled into a system metalanguage file, VB7Lang.vbi.
You can see the system metalanguage files on the settings form in gmStudio:
One of system gmSL scripts is authortext.gmsl. This script is processed by the the system metalanguage script. vb7lang.xml:
The script contains routines that author "boilerplate" content that cannot be generated from the VB6 source; for example configurations in the csproj file, AssemblyInfo files, resx files, and many other blocks of "boiler plate" text that are added to the translation results.
At the top of Authortext.gmsl you will find two empty routines:
These routines are called by gmBasic when it authors the .NET project file. They may be modified to add custom assembly references and code file references.
One option for doing this is to use a project-specific metalang as described here Custom VB6 Language Replacement.
A less involved option is to add a gmSL block to your translation script for example:
This effectively overrides the default implementation with the one provided. The effect on the csproj file can be seen in this difference report: