Skip to main content
All docs
V25.1
  • CommonObjectLockSettings.DisableMoving Property

    Disables the ability to move the current shape on the slide.

    Namespace: DevExpress.Docs.Presentation

    Assembly: DevExpress.Docs.Presentation.v25.1.dll

    NuGet Package: DevExpress.Docs.Presentation

    Declaration

    public bool DisableMoving { get; set; }

    Property Value

    Type Description
    Boolean

    true if a user cannot move the shape; otherwise, false.

    Example

    The following code snippet locks all user operations for shapes:

    using DevExpress.Docs.Presentation;
    using System.Drawing;
    
    namespace PresentationApiSample;
    
    public class Program {
        public static void Main(string[] _) {
            // ...
            shape.LockSettings.DisableArrowheadsChange = true;
            shape.LockSettings.DisableAspectRatioChange = true;
            shape.LockSettings.DisableGrouping = true;
            shape.LockSettings.DisableHandles = true;
            shape.LockSettings.DisableMoving = true;
            shape.LockSettings.DisablePointsEdit = true;
            shape.LockSettings.DisableResize = true;
            shape.LockSettings.DisableRotation = true;
            shape.LockSettings.DisableSelection = true;
            shape.LockSettings.DisableShapeTypeChange = true;
            shape.LockSettings.DisableTextEdit = true;
    
            group.LockSettings.DisableAspectRatioChange = true;
            group.LockSettings.DisableGrouping = true;
            group.LockSettings.DisableMoving = true;
            group.LockSettings.DisableRotation = true;
            group.LockSettings.DisableSelection = true;
            group.LockSettings.DisableUngrouping = true;
            group.LockSettings.DisableResize = true;
    
            picture.LockSettings.DisableSelection = true;
            picture.LockSettings.DisableArrowheadsChange = true;
            picture.LockSettings.DisableAspectRatioChange = true;
            picture.LockSettings.DisableCropping = true;
            picture.LockSettings.DisableGrouping = true;
            picture.LockSettings.DisableHandles = true;
            picture.LockSettings.DisableMoving = true;
            picture.LockSettings.DisablePointsEdit = true;
            picture.LockSettings.DisableResize = true;
            picture.LockSettings.DisableRotation = true;
            picture.LockSettings.DisableSelection = true;
            picture.LockSettings.DisableShapeTypeChange = true;
    
            connector.LockSettings.DisableArrowheadsChange = true;
            connector.LockSettings.DisableAspectRatioChange = true;
            connector.LockSettings.DisableGrouping = true;
            connector.LockSettings.DisableHandles = true;
            connector.LockSettings.DisableMoving = true;
            connector.LockSettings.DisablePointsEdit = true;
            connector.LockSettings.DisableResize = true;
            connector.LockSettings.DisableRotation = true;
            connector.LockSettings.DisableSelection = true;
            connector.LockSettings.DisableShapeTypeChange = true;
        }
    }
    
    See Also