habib ullah

habib ullah

  • NA
  • 229
  • 14k

we load the drop down of another combo then give me error

Jan 29 2019 12:20 PM
these are store procedure
 
alter procedure GetCompanyForSell
as
begin
select c.Name, c.companyid from Tbl_Product as p join Tbl_Company as c on c.companyid=p.company_id
where p.Quantity>0
end
end
when load then give error
Additional information: Input string was not in a correct format.Couldn't store in ddd Column. Expected type is Int32. 
the code is given below
 
public void GetCompany()
{
DataRow dr;
List prm = new List();
DataSet ds = rp.GetDS("GetCompanyForSell", prm);
DataTable dt = ds.Tables[0];
dr = dt.NewRow();
dr.ItemArray = new object[2] { 0, "?????? ????" };
dt.Rows.InsertAt(dr, 0);
cmb_company.DataSource = dt;
cmb_company.DisplayMember = "Name";
cmb_company.ValueMember = "ddd";
}
please solve the problems 
 

Answers (1)