How do I set up a blank grid to start inserting data? All I get is a blank screen
I am using VS 2010 with a trial copy of Telerik RAD controls
I am using VS 2010 with a trial copy of Telerik RAD controls
<%@ Page Title="" Language="VB" MasterPageFile="~/Brunswick.master" AutoEventWireup="false" CodeFile="FastItemEntry.aspx.vb" Inherits="FastItemEntry" %> |
<asp:Content ID="cntHead" ContentPlaceHolderID="cpHead" Runat="Server"> |
</asp:Content> |
<asp:Content ID="cntBody" ContentPlaceHolderID="cpHolder" Runat="Server"> |
<telerik:RadScriptManager ID="rsManager" Runat="server"> |
</telerik:RadScriptManager> |
<telerik:RadAjaxManager ID="raManager" runat="server"> |
</telerik:RadAjaxManager> |
<table border="0" cellpadding="0" cellspacing="0"> |
<tr> |
<td> |
<telerik:RadGrid ID="rgAddItems" AutoGenerateColumns="False" GridLines="Both" runat="server"> |
<MasterTableView DataKeyNames="ItemID" CommandItemDisplay="Bottom" NoDetailRecordsText="begin entering data" runat="server"> |
<Columns> |
<telerik:GridBoundColumn DataField="ItemID" Visible="false" /> |
<telerik:GridBoundColumn UniqueName="PartNumber" DataField="PartNumber" HeaderText="Part Number" /> |
<telerik:GridBoundColumn UniqueName="ItemDescription" DataField="ItemDescription" HeaderText="Description" /> |
<telerik:GridTemplateColumn> |
<ItemTemplate> |
<asp:Label ID="lblQty" runat="server" /> |
</ItemTemplate> |
<EditItemTemplate> |
<telerik:RadNumericTextBox ID="rntbQty" NumberFormat-DecimalDigits="0" NumberFormat-GroupSizes="9" runat="server" > |
</telerik:RadNumericTextBox> |
</EditItemTemplate> |
</telerik:GridTemplateColumn> |
</Columns> |
</MasterTableView> |
</telerik:RadGrid> |
</td> |
</tr> |
</table> |
</asp:Content> |
Imports System.Data |
Partial Class FastItemEntry |
Inherits System.Web.UI.Page |
Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load |
If Page.IsPostBack Then |
Else |
rgAddItems.MasterTableView.IsItemInserted = True |
rgAddItems.Rebind() |
End If |
End Sub |
Protected Sub rgAddItems_ItemCommand(ByVal source As Object, ByVal e As Telerik.Web.UI.GridCommandEventArgs) Handles rgAddItems.ItemCommand |
End Sub |
Protected Sub rgAddItems_NeedDataSource(ByVal source As Object, ByVal e As Telerik.Web.UI.GridNeedDataSourceEventArgs) Handles rgAddItems.NeedDataSource |
Dim dt As DataTable = Nothing |
rgAddItems.DataSource = dt |
End Sub |
End Class |