Click here to Skip to main content
15,891,633 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
C#
string[] strarr;

DataTable dt1 = Commanclass.returnData("Select product+'==='+Packsize as Product from WholeSalerStock where wholesalerid=" + ddlWholeSaler.Text + " order by Product");
DataRow[] dr11 = dt1.Select();
strarr = Array.ConvertAll(dr11, new Converter<datarow,>(DataRowToString));

public static string DataRowToString(DataRow dr)
{
return dr["Product"].ToString();
}

gvProductPack.DataSource = from str in strarr where str.ToUpper().StartsWith(TextBox1.Text.ToUpper()) select str;
gvProductPack.DataBind()


This is my code But It works for single column i want to bind 2 more column as Whcode,Packsize to gridview. so what kind of changes r required here plz suggest me
Posted
Updated 7-Jul-12 2:47am
v2

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900