Set Grid CurrentPosition

2 posts, 0 answers
  1. Eric Klein
    Eric Klein avatar
    183 posts
    Member since:
    Aug 2009

    Posted 12 Jul 2012 Link to this post

    I have a screen with a gridview on it where the user can select a row and it populates information on the screen.  In the edit section I have created a Next and Previous button
    private void NextButton_Click(object sender, System.Windows.RoutedEventArgs e)
            {           
                GeneralLedgerGridView.Items.MoveCurrentToNext();
                var selectCommand = RadGridViewCommands.SelectCurrentUnit as RoutedUICommand;
                selectCommand.Execute(null, this.GeneralLedgerGridView);
            }

    The problem is is if the user clicks on a row with the mouse then hit the previous or next button the application seems unaware of the current row that was selected by the mouse click.  How do I set the Currentrow info on a mouse click.
  2. Eric Klein
    Eric Klein avatar
    183 posts
    Member since:
    Aug 2009

    Posted 12 Jul 2012 Link to this post

    I figured out  the issue I need to set   IsSynchronizedWithCurrentItem="True"  in the RadGridView

  3. UI for WPF is Visual Studio 2017 Ready
Back to Top