protected void RowDataBound(object sender, EventArgs e) { string campo = DeployView.Rows[0].Cells[5].Text; }
protected void gridview_ItemDataBound(object sender, GridItemEventArgs e) { if (e.Item.ItemType == GridItemType.Item | e.Item.ItemType == GridItemType.AlternatingItem) { GridDataItem itemCorrente = (GridDataItem)e.Item; // e poi vado a cercarmi quello che mi serve: // Es. // itemCorrente.Cells(0).Text // itemCorrente.Cells(0).Controls.Item(0).Visible // In alternativa usi un findControl se hai più controlli nella cella che controlli } }
Torna al forum | Feed RSS