开发者

disable window gridview get focus on first row

开发者 https://www.devze.com 2023-02-14 21:21 出处:网络
Hi how do i disable the window gridview get focus on the first row? i tried开发者_StackOverflowgvStudents.ClearSelection(); on the form load, but it did not do the trick.

Hi how do i disable the window gridview get focus on the first row? i tried开发者_StackOverflow gvStudents.ClearSelection(); on the form load, but it did not do the trick. please advice


Try calling ClearSelection() in the DataBindingComplete event.


in devexpress when you activate multi selection mode, it actually doesn't get focused to the first row, but instead it selects the first row. I had the same problem and have solved it by overriding the Onproperty changed event of the gridview .

      **protected override void OnPropertyChanged(DependencyPropertyChangedEventArgs e)
{ base.OnPropertyChanged(e);
  this.ClearSelection();}
       }**
0

精彩评论

暂无评论...
验证码 换一张
取 消