G
Guest
i am posting below code i am not sure how to call parametrized store
procedure and fill the grid.
....
I have store procedure which pull the info from sql server 2005 using
asp.net 1.1... that proc accept two parameters .
any body has any idea how to do that thing using dataset ....
thanks
public DataSet GetCustByDate(int MonthNo,string YearNo)
{
strSQL="dbo.sp_GetCust " + MonthNo.ToString() + " , " + YearNo;
SqlConnection conn = this.GetConnection();
conn.Open();
SqlDataAdapter myCommand = new SqlDataAdapter(strSQL, conn);
DataSet ds = new DataSet();
myCommand.Fill(ds, strSQL);
conn.Close();
return ds;
}
procedure and fill the grid.
....
I have store procedure which pull the info from sql server 2005 using
asp.net 1.1... that proc accept two parameters .
any body has any idea how to do that thing using dataset ....
thanks
public DataSet GetCustByDate(int MonthNo,string YearNo)
{
strSQL="dbo.sp_GetCust " + MonthNo.ToString() + " , " + YearNo;
SqlConnection conn = this.GetConnection();
conn.Open();
SqlDataAdapter myCommand = new SqlDataAdapter(strSQL, conn);
DataSet ds = new DataSet();
myCommand.Fill(ds, strSQL);
conn.Close();
return ds;
}