Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Explicit definitions of columns required?
Message
From
13/08/2014 17:39:57
 
 
To
13/08/2014 15:13:47
General information
Forum:
ASP.NET
Category:
WebForms
Environment versions
Environment:
C# 5.0
OS:
Windows Server 2012
Network:
Windows 2008 Server
Database:
MS SQL Server
Application:
Web
Miscellaneous
Thread ID:
01605604
Message ID:
01605615
Views:
27
>>Trying to get an editable GridView to work in a Web form -
>>
>>here's the GridView definition
>>
>>    asp:GridView ID="GV1" runat="server" AutoGenerateEditButton="True" 
>>        OnRowEditing = "GV1_RowEditing"
>>        OnRowUpdating = "GV1_RowUpdating"
>>        CellPadding="10" CellSpacing="10" BorderStyle="Solid" 
>>        HorizontalAlign="Center" Caption="DashBoard Configuration Settings" 
>>        CaptionAlign="Top">
>>        <EditRowStyle BackColor="#9999FF" />
>>    /asp:GridView>
>>
>>
>>Everything I've read says that in the GV1_RowEditing event all I need is
>>
>>       protected void GV1_RowEditing(object sender, GridViewEditEventArgs e)
>>        {
>>            GV1.EditIndex = e.NewEditIndex;
>>            GV1.DataSource = GVSet;
>>            GV1.DataBind();
>>        }
>>
>>
>>And the Gird should show up with the input equivalents for the fields....However nothing shows after I click on the 'Edit' - no Grid, nada, nichts, nils
>>
>>With the exception of one forum post, I did notice that most everyone explicitly defines the columns for the Grid. Is that required in order to do what I want to do?
>>
>>Thanks
>
>Did you try setting the autogenerate property to True?

AutoGenerate defaults to True. We finally figured out that the DataSet that actually held the data was getting lost....out there somewhere....in the weeds, or something - it's .Net, who knows?
"You don't manage people. You manage things - people you lead" Adm. Grace Hopper
Pflugerville, between a Rock and a Weird Place
Previous
Reply
Map
View

Click here to load this message in the networking platform