Protected Sub Page_Init(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Init
Dim PlaceHolder1 As PlaceHolder
Dim RadGrid1 As RadGrid = New RadGrid
Dim sql As String = "SELECT [ProductName] From Products order by ProductName"
Dim GridDataSet As DataSet = CDSSQLFunctions.GetDataSet(sql)
Dim boundColumn As GridBoundColumn
RadGrid1.Skin = "Default"
RadGrid1.Width = Unit.Percentage(100)
RadGrid1.PageSize = 5
RadGrid1.AllowPaging = True
RadGrid1.AutoGenerateColumns = False
RadGrid1.GroupingEnabled = True
RadGrid1.ShowGroupPanel = True
RadGrid1.MasterTableView.PageSize = 15
BoundColumn = New GridBoundColumn
boundColumn.DataField = "ProductName"
boundColumn.HeaderText = "ProductName"
RadGrid1.MasterTableView.Columns.Add(boundColumn)
RadGrid1.DataSource = GridDataSet
RadGrid1.DataBind()
PlaceHolder1 = phGrid ' <asp:PlaceHolder ID="phGrid" runat="server"></asp:PlaceHolder><br />
PlaceHolder1.Controls.Add(RadGrid1)
End Sub