Posted on: 6/9/2014 2:23:08 AM | Views : 392

Seems like it couldnt search with the date with the syntax,
having said that : 
The conversion of a varchar data type to a datetime data type resulted in an out-of-range value.
if (txtDate.Text != "") { DataTable dt1 = Products.GetSupplierCost_ByDate(Convert.ToDateTime(txtDate.Text)); if (dt1 != null) { gvSupplierCost.DataSource = dt1; gvSupplierCost.DataBind(); udpAdjustCost.Update(); } } public static DataTable GetSupplierCost_ByDate(DateTime dtCostIncomingDate) { string strConnString = ConnString.getConnString(); using (SqlConnection sqlconn = new SqlConnection(strConnString)) { DataTable dt = new DataTable(); string strSQL = "Select * from productcosttable WHERE costincomingdate = '" + dtCostIncomingDate + "'& ...

Go to the complete details ...