Force a command line parameter to a value

Hello Forum,

I’d like to force the “distance” parameter in the “offset” command-line command to a specific value. Is there a way to do it? I’m working under RhinoCommon

Thanks. L

How about this?

RhinoApp.RunScript("_Offset _Distance=3.0 ...

You can also just use Rhino.Geometry.Curve.Offset.

http://developer.rhino3d.com/api/RhinoCommonWin/html/Overload_Rhino_Geometry_Curve_Offset.htm

– Dale

Dale,

thanks.

I’ve been to short in the problem description and sadly in my specific case both of your advises do not solve it.

I have to operate on the command line and set the offset to a fixed value. In the same time I don’t want the user to be able to modify it.

In other words what I need is a custom command-line command where the _Distance parameter is not listed or is set read only. Is it feasible?

Thanks. L

Sorry no. The only way of doing this is to write your own Offset command…

Dale,

not even feasible to force a range for that parameter?

Thanks. L

Basically, a plug-in cannot change the behavior of an existing command.

If you want a version of the Offset command that limits the distance to some range, then you’ll need to provide your own command.

Does this help?

– Dale

Dale,

Thanks. L