We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Locking a diagram so nothing can be moved

Thread ID:

Created:

Updated:

Platform:

Replies:

77002 Oct 6,2008 02:48 PM UTC Oct 8,2008 01:37 PM UTC WinForms 3
loading
Tags: Diagram
Ron Alan Sawyer
Asked On October 6, 2008 02:48 PM UTC

In my current project I have two views of my diagrams:
1. Edit/Creation view
2. Display. I do not want the user to be able to change/move controls in display mode. I would like to be able to "lock" the diagram.

How can I do this?


Ron Alan Sawyer
Replied On October 6, 2008 03:22 PM UTC

Have a look at node.editstyle. It has several properties to allow and disallow movement, resizing etc.


Administrator [Syncfusion]
Replied On October 8, 2008 04:34 AM UTC

Hi RAS,

Yes, its very much possible for having the digram control behave just in the way you desire, i.e workable, when in edit mode; and disabled when in the display mode.

To do this you can follow these steps:
1. Create two buttons (For interactive features)

2. Label them, "Edit Mode" and "Display Mode"

3. Add the following line of text into the click event associated with the button labeled "Edit Mode":

diagram1.Enabled = True;

4. Add the following line of text into the click event associated with the button labeled "Display Mode":

diagram1.Enabled = False;

Run the code to see the difference.

PS: Dont forget to post you experiences!

Happy Coding!


Ron Alan Sawyer
Replied On October 8, 2008 01:37 PM UTC

Thanks, your way is easier than mine was!


CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Please sign in to access our forum

or the page will be automatically redirected to sign-in page in 10 seconds.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

;