I want to convert string value to List.How to Convert this.
Here is My Code.
private void TestGridData_CellContentClick(object sender, DataGridViewCellEventArgs e)
{
DataGridViewRow row = new DataGridViewRow();
List
int I = TestGridData.CurrentCell.ColumnIndex;
string Head = TestGridData.Columns[I].Name;
if (Head == "check")
{
row = TestGridData.CurrentRow;
int row2 = row.Index;
TestCost = Convert.ToInt32(TestGridData[2, row2].Value);
string Name = TestGridData[1, row2].Value.ToString();
}
// TestName=Name as List
sum = sum + TestCost;
txtcost.Text = sum.ToString();
}
And the string value stored in Name and list stored in TestName.How to convert this Name to List.In this the commented line i tried but i didn't get correct output.
Please help me to get correct output

Manas MohapatraPosted Aug 7, 2015, 6:27 AM
int I = TestGridData.CurrentCell.ColumnIndex;
string Head = TestGridData.Columns[I].Name;
if (Head == "check")
{
row = TestGridData.CurrentRow;
int row2 = row.Index;
TestCost = Convert.ToInt32(TestGridData[2, row2].Value);
}
Pranay RanaPosted Aug 7, 2015, 6:30 AM