Click here to Skip to main content
15,884,537 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi,
am developing a Windows 8.1 app using C# and xaml.
I have page in that i have 2 rows and 2 columns like below.
What i want to do is when i press and hold(selected item) the 1st grid and i want to move it to the 4th grid, then 4th grid should be move to 1st grid and 1st grid has to move to the 4th grid.(swapping/moving).
How can i achieve this?
Anybody please help me
Posted
Comments
Afzaal Ahmad Zeeshan 8-Oct-14 4:04am    
I think you need to RemoveChild elements and Children.Add(childControl) to the parent control. Too technical?

Get it like this, when you click on the element you save a new instance of that control or you duplicate it, then when you need to move it, you delete that control which was clicked, and you create a new control inside the 4th grid with same controls.
ashok rathod 8-Oct-14 23:02pm    
i think you can simple change the upper level grid row and column property and can achieve this functionality

1 solution

i can able to move the grid view items from 1 to 2, 2 to 4, 3 to 4 and 4 to 3.
But when i move the 1st item to 4th, both of them has to be replaced.. means, 1st item has to move to 4th one and 4th item has to replace the 1st item.
How can i achieve this?
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900