0

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#?

David
  • 161
  • 2
  • 10

1 Answers1

1

You can set it like this, for example:

Button b = new Button();

b.SetValue(DraggableExtender.CanDragProperty, true);
Chris Mack
  • 5,096
  • 2
  • 9
  • 28