Acad export schemes - how to access via script

Hi there,

This issue has been raised by me in the past, as long ago as V4… Doesn’t look like there is an easy way to access AutoCAD (dxf,dwg) export settings/schemes in a script… I thought by now that the schemes might be stored in the general .xml settings file, but I don’t see anything there. Previously, they weren’t even exposed in a visible registry key, there was a hack to get at them via the registry that Dale posted once, but it’s not an easy one.

I didn’t see anything either in RhinoCommon that looked promising, maybe I missed something…

For me at least it would be useful to see what schemes the user has stored so as to be able to set one on export; far better would be to be able to create a scheme in the script or be able to set the export parameters without having to create a scheme first.

Has any progress been made on this or is it still in the V4 and earlier stage…?

Thanks, --Mitch

Does -_AcadSchemes do anything for you?

Hey Lowell,

Well, almost… it lacks a “list” option where I can see all the schemes that are already there; I don’t want to be trying to overwrite something that is already there, but if it is there I do need to verify that it has the correct options set.

The command won’t let me create a new scheme with a name that exists, and you can only edit the current scheme. So I would have to first try to make the scheme name I want current and see if that fails (don’t know how to detect that), then create a new one with the right settings; or, if the scheme does exist, I would have to try to check/edit it, which is nearly impossible…

So, no, it doesn’t help me much, unfortunately - unless I’m completely missing some option.

Edit:
Oh, I guess I could make it import a preset .ini - which I suppose I could write out with the script - but that is always a pain with file save permissions, and I still don’t know about overwriting an existing scheme…

–Mitch

OK. That’s all there is.
I guess moving it from registry to the xml file would be the only hope of something in a tractable time range.
I’ll see what the chances of that are.

OK, thanks Lowell. As -AcadSchemes (dash version) doesn’t do anything in V5 Windows or Mac, this is moot as I will have a lot of V5 “clients” on both platforms to work with for awhile yet… Unfortunately, the Mac side (V5 or WIP) doesn’t seem to allow a scheme import either @dan . So I’m basically back to square one here anyway…

Cheers, --Mitch

Yep, that one’s been on our radar for awhile. Thanks. Good to check.