Reputation: 171
I've found this code which allows dragging a control around a canvas.
What is the way to add this draggable property programmatically to a control that's created in C#?
Upvotes: 0
Views: 33
Reputation: 5208
You can set it like this, for example:
Button b = new Button();
b.SetValue(DraggableExtender.CanDragProperty, true);
Upvotes: 1