Last Updated: 19 Feb 2018 15:05 by ADMIN
Dess | Tech Support Engineer, Sr.
Created on: 02 May 2016 09:23
Category: VirtualGrid
Type: Bug Report
FIX. RadVirtualGrid - NullReferenceException when pressing PageDown/PageUp keys after the grid is loaded
A newly created grid has its CurrentCell property initialized to Nothing. Pressing [PageDown] or any other key that causes scrolling will crash.

Steps to Reproduce:
1. Launch application
2. Press [PageDown]

 Sub New() 

        Me.RadVirtualGrid1.ColumnCount = 50
        Me.RadVirtualGrid1.RowCount = 100
        AddHandler Me.RadVirtualGrid1.CellValueNeeded, AddressOf RadVirtualGrid1_CellValueNeeded
    End Sub

    Private Sub RadVirtualGrid1_CellValueNeeded(sender As Object, e As Telerik.WinControls.UI.VirtualGridCellValueNeededEventArgs)
        e.Value = e.ColumnIndex
    End Sub


Me.RadVirtualGrid1.CurrentCell = New Telerik.WinControls.UI.VirtualGridCellInfo(0, 0, Me.RadVirtualGrid1.MasterViewInfo)
(Total attached files size should be smaller than 20mb. Allowed extensions: .zip, .rar, .jpg, .png, .gif)
Dess | Tech Support Engineer, Sr.
Posted on: 19 Feb 2018 15:05
Hello Anujith,

Initially, RadVirtualGrid doesn't have a current cell. In the Load event of the Form, you can set the CurrentCell property to the first cell. Note that this issue has already been addressed. Feel free to upgrade in order to benefit from the fix.
Posted on: 26 Oct 2017 05:02
where to place workaround code