1 - 在GridView中有GridView和一个按钮
2 - 如何使用按钮
从此网格中获取特定值.aspx的:
<asp:GridView ID="gvCalc" runat="server" AutoGenerateColumns="false">
<Columns>
<asp:BoundField DataField="tx_desc" />
</Columns>
</asp:GridView>
<asp:Button ID="btnGetValue" runat="server" OnClick="btnGetValue_Click" />
<asp:Label ID="lbError" runat="server"></asp:Label>
C#:
protected void btnGetValue_Click(object sender, EventArgs e)
{
lbError.Text = gvCalc.Rows[0].Cells[0].ToString();
//lbError RETURNS 'System.Web.UI.WebControls.DataControlFieldCell'
//I DONT WANT THAT...I WANT THE VALUE
}