A community member has associated this post with a similar question:
WPF + Move/resize child controls in grid panel

Only moderators can edit this content.

WPF - Move/resize child controls in grid panel

Gagan 1 Reputation point
2022-04-14T14:25:43.373+00:00

Hi,
I have a requirement where child controls inside the grid panel should be movable/draggable to other grid cells. Also, it should be resizable to other grid cell by dragging the child control's border.
For ex, I have a Grid panel with 4 * 4(rows*columns) and having textblock as a child control(Grid.Row=1,Grid.column=2). Now I should be able to move this textblock to other grid cell through mouse event( for ex, Grid.Row=2,Grid.column=3) and resize it to occupy next grid cell (Grid.Row=1,Grid.column=3)

Please let me know how can we achieve it.
Thanks
Gagan

Windows Presentation Foundation
Windows Presentation Foundation
A part of the .NET Framework that provides a unified programming model for building line-of-business desktop applications on Windows.
2,683 questions
0 comments No comments
{count} votes