WPF.DragInGridsRowsReorder Example

10 posts, 0 answers
  1. Richard Harrigan
    Richard Harrigan avatar
    235 posts
    Member since:
    Nov 2009

    Posted 10 Apr 2013 Link to this post

    Hi,

    How would you modify this program so that when dragging it shows the contents of the ID or UserName column.  Ideally this might be done when calling RowOrderBehaviorSetIsEnable(Grid1, true).  This would allow the code to handle more than 1 data format.

    Thanks
    Rich
  2. Nick
    Admin
    Nick avatar
    593 posts

    Posted 11 Apr 2013 Link to this post

    Hi Richard,

    I am not sure I understood your question correctly, but, using the example, you can modify the DraggedItemTemplate in the GridView Resources to show any of the dragged item properties. 

    Is that what you are looking for? 

    All the best,
    Nik
    the Telerik team

    Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

  3. UI for WPF is Visual Studio 2017 Ready
  4. Richard Harrigan
    Richard Harrigan avatar
    235 posts
    Member since:
    Nov 2009

    Posted 11 Apr 2013 Link to this post

    Hi Nik

    I was referring to another example with two side by side grids.  I got that working but the example did not have a data template in xaml where I could change the displayed content..  I originally was going to try your example but it does not show all the xaml code.  Could you send me a compilable version of the example.  Or please explain in detail how to get the examples myself.  I've tried before without success.

    Thanks
    Rich
  5. Nick
    Admin
    Nick avatar
    593 posts

    Posted 11 Apr 2013 Link to this post

    Hi Richard,

    I am attaching an example with the RowReordering behavior. 

    Hope it helps! 

    Kind regards,
    Nik
    the Telerik team

    Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

  6. Richard Harrigan
    Richard Harrigan avatar
    235 posts
    Member since:
    Nov 2009

    Posted 11 Apr 2013 Link to this post

    Hi Nik

    The example did not compile.  I got the following error:

    The project file contains a property value that is not valid'

    Thanks
    Rich
  7. Nick
    Admin
    Nick avatar
    593 posts

    Posted 11 Apr 2013 Link to this post

    Hello Richard,

    May I ask you for some additional information? 
    What is the Version of our controls you are using? What is the Visual Studio version you are compiling the project on? 

    Looking forward to your response! 

    All the best,
    Nik
    the Telerik team

    Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

  8. Richard Harrigan
    Richard Harrigan avatar
    235 posts
    Member since:
    Nov 2009

    Posted 11 Apr 2013 Link to this post

    Hi Nik

    Version 2013.1.220.40
    Runtime version V4.0.30319

    Express 2012 for Windows Desktop

    Rich
  9. Nick
    Admin
    Nick avatar
    593 posts

    Posted 15 Apr 2013 Link to this post

    Hello Richard,

    That is very strange. We are able to build it on every machine we have. 
    Can you change the runtime of the project to .Net 4.0 instead of ClientProfile and see if that helps?

    Looking forward to your reply! 

    Kind regards,
    Nik
    the Telerik team

    Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

  10. Richard Harrigan
    Richard Harrigan avatar
    235 posts
    Member since:
    Nov 2009

    Posted 15 Apr 2013 Link to this post

    Hi Nik,

    More strangeness.  I downloaded the app again and this time it the app worked???  I also tried it out with 4.0 and 4.5 and that also worked.  But know for the really strange part.  When I open the xaml file I get squiggle lines for GridViewRow and any other GridViewRow related property.  How do I still get a clean compile and the app works???

    i.e
    GridviewRow, DragDropManager does not exist in namespace

    <Style TargetType="telerik:GridViewRow"

    x:Key="DraggedRowStyle">

    <Setter Property="telerik:DragDropManager.AllowDrag"

    Value="True" />

    <Setter Property="telerik:DragDropManager.TouchDragTrigger"

    Value="TapAndHold"/>

    </Style>



    Thanks
    Rich

  11. Richard Harrigan
    Richard Harrigan avatar
    235 posts
    Member since:
    Nov 2009

    Posted 15 Apr 2013 Link to this post

    Hi Nik,

    I deleted the Lib folder and the xaml errors went away.  I will review your example and get back to you if I have any questions (I probably will, I'm not the sharpest knife in the drawer).

    Thanks
    Rich
Back to Top
UI for WPF is Visual Studio 2017 Ready