Home Forums General XMetaL Discussion Run batch file from macro Reply To: Run batch file from macro

Derek Read

Reply to: Run batch file from macro

Where is your MCR file normally located? My answer will vary depending on its actual location. The path I'm looking for is not necessarily the full path but a path relative to other files your customization depends on, specifically the DTD/XSD, or if you distribute your customization inside an XAC file. Or if it is an application-level MCR file then I would expect it to be located in the Startup folder.

We are using part of the Windows system to run the bat file (WScript.Shell) and it requires a full path in this case, so that path would be built based on this other information. There are various APIs that allow you to find the XMetaL installation location as well as some that allow you to easily convert between full and relative paths, locate the currently loaded “rules file” (DTD/XSD) etc and one or more of these will likely come into play.

Reply

Products
Downloads
Support