protected void gvInfo_RowDataBound(object sender, GridViewRowEventArgs e)
{
if (e.Row.RowType == DataControlRowType.DataRow)
{
switch (id)
{
case "1":
e.Row.Cells[12].Visible = false;
e.Row.Cells[13].Visible = false;
gvInfo.HeaderRow.Cells[12].Visible = false;
gvInfo.HeaderRow.Cells[13].Visible = false;
break;

case "6":
e.Row.Cells[11].Visible = false;
e.Row.Cells[12].Visible = false;
gvInfo.HeaderRow.Cells[11].Visible = false;
gvInfo.HeaderRow.Cells[12].Visible = false;
break;

default:
e.Row.Cells[11].Visible = false;
e.Row.Cells[13].Visible = false;
gvInfo.HeaderRow.Cells[11].Visible = false;
gvInfo.HeaderRow.Cells[13].Visible = false;
break;
}
}
}

05-07 15:25