Code:
string imgg=1,3,4,9,18,
imgg=imgg.TrimEnd(',');
string[] words = imgg.Split(',');
foreach (string word in words)
{
strrr = "select * from profiles where proid=" + int.Parse(word);
SqlDataSource2.SelectCommand = strrr;
GridView2.DataSourceID = "sqldatasource2";
GridView2.DataBind();
}
Comment