Lock the start point of a RadDiagramConnection from being edited

2 posts, 1 answers
  1. Adam
    Adam avatar
    4 posts
    Member since:
    Aug 2017

    Posted 18 Aug 2017 Link to this post

    I have a diagram control, I'm using GraphSource to bind to a list of my business objects. I then use protected override IConnection GetConnectionContainerForItemOverride(object item) to choose a connection based on the specific business object. In my case I'm either using RadDiagramConnection directly, or a custom implementation that inherits from RadDiagramConnection.

    My goal is to disable the ability for my users to disconnect the start point of my connector in some situations  - thus the GetConnectionContainerForItemOverride override to select a custom implementation of RadDiagramConnection.

    In my custom implementation of RadDiagramConnection constructor I've tried to listen to various events, I've tried to clear the connection points, and manipulation points, but no no affect. I cannot detect that the user is trying to move the start point, and then cancel, nor can I remove the point so the users cannot drag it around when the connection is selected in the diagram at run time.

    Any thoughts on how I can disable the ability for my users to remove the start connection of my connection line on a diagram control?

    Thanks for any thoughts you have about this!

  2. Answer
    Petar Mladenov
    Petar Mladenov avatar
    3018 posts

    Posted 23 Aug 2017 Link to this post

    Hello Adam,

    Please read the documentation of Connection Manipulation events. They are especially designed to plug into and control the manipulation process of connections. If they do not help, please post some code that we can advice more precisely.

    Petar Mladenov
    Progress Telerik
    Want to extend the target reach of your WPF applications, leveraging iOS, Android, and UWP? Try UI for Xamarin, a suite of polished and feature-rich components for the Xamarin framework, which allow you to write beautiful native mobile apps using a single shared C# codebase.
Back to Top