Source Error:
Line 248: //{
Line 249:
Line 250: int RollNo = Convert.ToInt32 (str.ToString(s tr.Append(GridV iew1.Rows[i].Cells[1].Text)));
Line 251:
Line 252: DeleteStudent(R ollNo);
Source File: h:\Office Works\Projects\ Sample Applications\Gr idViewVitCode.a spx.cs Line: 250
Plz solve this problem.
This is the actual full code
for (int i = 0; i < GridView1.Rows. Count; i++)
{
StringBuilder str = new StringBuilder() ;
GridViewRow row = GridView1.Rows[i];
bool isChecked = ((CheckBox)row. FindControl("Ch eckBox1")).Chec ked;
if (isChecked)
{
//str.Append(Grid View1.Rows[i].Cells[1].Text);
// Column 2 is the name column
int RollNo = Convert.ToInt32 (str.ToString(s tr.Append(GridV iew1.Rows[i].Cells[1].Text)));
DeleteStudent(R ollNo);
//Refresh Grid
BindGrid();
}
Line 248: //{
Line 249:
Line 250: int RollNo = Convert.ToInt32 (str.ToString(s tr.Append(GridV iew1.Rows[i].Cells[1].Text)));
Line 251:
Line 252: DeleteStudent(R ollNo);
Source File: h:\Office Works\Projects\ Sample Applications\Gr idViewVitCode.a spx.cs Line: 250
Plz solve this problem.
This is the actual full code
for (int i = 0; i < GridView1.Rows. Count; i++)
{
StringBuilder str = new StringBuilder() ;
GridViewRow row = GridView1.Rows[i];
bool isChecked = ((CheckBox)row. FindControl("Ch eckBox1")).Chec ked;
if (isChecked)
{
//str.Append(Grid View1.Rows[i].Cells[1].Text);
// Column 2 is the name column
int RollNo = Convert.ToInt32 (str.ToString(s tr.Append(GridV iew1.Rows[i].Cells[1].Text)));
DeleteStudent(R ollNo);
//Refresh Grid
BindGrid();
}
Comment