[gme-users] Calling 'MGA.Interpreter.MetaGME2Uml' Programatically
Chris vanBuskirk
Chris.vanBuskirk at vanderbilt.edu
Sun Apr 27 14:05:25 CDT 2008
GME Users,
I am attempting to invoke the 'MGA.Interpreter.MetaGME2Uml' interpreter via
COM automation (i.e. in headless mode). A copy of my failing VB script is
provided at the bottom of this email.
I was expecting to receive a dialog interrogating me about the desired
output MGA filename, which would be a separate problem for a GUI-less mode
of operation. Instead, I am getting generic
catch(...)
{
AfxMessageBox("An application error has occured in component "
+ compname + ".\n"
"The system might not be in a stable state any more.\n"
"Please save your work and restart the GME.");
}
type error messages. Any insights about how to accomplish such a thing?
Barring that, where would I find the source code for that interpreter? I've
poked and prodded a bit, but I think maybe I'm looking in the wrong place
for this interpreter's sources.
Thanks Much,
Chris
<code>
' USAGE: Meta2UML.vbs infile outfile
' Imports a MetaGME paradigm definition and converts to GME-UML (for
UDM)
'
' Arguments:
' 1. infile : input MGA model
' 2. outfile: export meta to UML format
'
infile = WScript.arguments.item(0)
outfile = WScript.arguments.item(1)
Set mga = CreateObject("Mga.MgaProject")
Set launcher= CreateObject("Mga.MgaLauncher")
interpreter = "MGA.Interpreter.MetaGME2Uml"
mga.Open "MGA="&infile
launcher.RunComponent interpreter, mga, Nothing, Nothing, CLng(0)
mga.Close
</code>
More information about the gme-users
mailing list