70000664 Option to input point only on OSnap

Article 70000664
Type Wish
Product Engine
Version 7006
Date Added 12/15/2015 12:00:00 AM
Fixed 7.7007.0.2 (12/15/2015 12:00:00 AM)
Submitted by Wayne Romer

Summary

Is it possible in a active command that waits for a point to have this point ONLY on a OSnap ?

Solution

A new static property VectorDraw.Actions.BaseAction.AcceptedPoints was added in version 7007.0.2

Get/Set a static value of VectorDraw.Actions.BaseAction.AcceptedPointsFlag  type that controls when user waiting point actions successfully finsih by mouse click.
Default value is VectorDraw.Actions.BaseAction.AcceptedPointsFlag.AcceptedPointsFlag.All

VectorDraw.Actions.BaseAction.AcceptedPointsFlag , Controls when user waiting point actions successfully finish by mouse click and can get one of the following values:

 All :  user waiting point actions successfully finish for any click on screen.

OsnapsOnly :  When at least an osnap is enabled user waiting point actions successfully finish only if an Osnap is active over the mouse click.
                      When the Osnap is Disabled or None user waiting point actions successfully finish for any click on screen.


Example :

Set AcceptedPoints to OsnapsOnly for a getUserPoint

VectorDraw.Actions.BaseAction.AcceptedPointsFlag = VectorDraw.Actions.BaseAction.AcceptedPointsFlag.AcceptedPointsFlag.OsnapsOnly;
document.ActionUtility.getUserPoint();
VectorDraw.Actions.BaseAction.AcceptedPointsFlag = VectorDraw.Actions.BaseAction.AcceptedPointsFlag.AcceptedPointsFlag.All;

Send comments on this topic.