C# Tutorial: Add Draggable Auto-Aligning Buttons to Your C# Programs



C# Tutorial: Add Draggable Auto-Aligning Buttons to Your C# Programs

C# Tutorial: Add Draggable Auto-Aligning Buttons to Your C# Programs

You have a Windows Forms project and you want to be able to drag buttons to change the layout around at runtime. And, what’s more, you want the buttons to auto-arrange themselves after you’ve dragged them.

The auto-arranging part is easy. I’ve shown in previous videos how you can use a WinForms flowLayoutPanel to do that. I’ve also previously shown how to drag controls on a form. What isn’t so easy is combining draggable controls with a flowable layout. In this video, I show you everything you need to do in order to make this work.

For more C# Programming Projects, see this Playlist: https://www.youtube.com/playlist?list=PLZHx5heVfgEu45dRS8YzyNnHMRtJGWDxu

To understand file launching, I’d also recommend that you watch my lessons on programming a Disk Browser – which you can find here: https://youtu.be/fxcQJ3uuxek

Huw Collingbourne is author of numerous books on programming C, C#, Java, Ruby, Delphi and Object Pascal, pointers, recursion and programming adventure games. Find them all on Amazon.

To learn C# quickly, Huw’s book, available in paperback or for Kindle, is the perfect complement to these YouTube lessons.
The Little Book Of C# Programming (Amazon US): https://amzn.to/2JWDI0o
The Little Book Of C# Programming (Amazon UK): https://amzn.to/2YaCPtS

Keep in Touch
==============================
Subscribe to the Code With Huw YouTube channel: https://www.youtube.com/CodeWithHuw?sub_confirmation=1

Code With Huw on Facebook:
https://www.facebook.com/CodeWithHuw