I was wondering if there is a Method which let’s me verify the existence of Export scheme, before running the script. (Which might run into an Error, if the “Scheme” doesn’t exist).
I thought I could maybe check the existence of an Scheme File (*.ini) in the default folder location. I couldn’t find the location though.
So here a short summery:
Are there special Export Scheme files? And if so, where are they located?
Is there an alternative way of testing the Existence of Export Schemes?
not shure if the default Scheme names are exposed somewhere. But if the user created a new scheme using the _AcadSchemes dialog and closed / reopened Rhino since then, the scheme name is listed with its settings in the registry. You can find it here:
If ...Settings/SchemeName does not exist, you should might stop the exporter (EDIT: if it is not an existing default scheme name)
Btw. There is a visual dialog to just set the current dwg scheme _DWGExportOptionsDialog. You could pop this up before export, then script the export command and use _Enter when it asks for the scheme name if this is not too obtrusive…