aniketpatil1987 0 Newbie Poster

Hi there,
I have a project consisting of a asp.net webpage generating report of total usage per day of a pertucular item.
the code worked in CR 9 with VS 2008 but since i converted it to CR 13 with VS 2010 the report is throwing error as "Parameter values missing" whenever i add a parameter to the report.
the parameter is in subreport.
the report is visible correctly without parameters.
[dt2 has records and i have filled it above the mentioned code]
the code i wrote is show below-

crReport cr = new crReport();

cr.SetDatabaseLogon(gf.databaseUsername, gf.databasePass);

((ReportDocument)cr.Subreports["MenuReport"]).SetDataSource(dt2);

#region Parameter gathering
ParameterValues paramQuantity = new ParameterValues();
for (int i = 0; i < dt.Rows.Count; i++)
{
    dt2.Rows[i]["menuItemFK"] = jobBll.GetDataInfo("M_MenuItems", "id", dt.Rows[i]["menuItemFK"].ToString(), "menuItemName", true);

    string menuItemFK = dt.Rows[i]["menuItemFK"].ToString();
    string reportDate = dt.Rows[i]["reportDate"].ToString();

    DataTable dtQuntity = new DataTable();
    dtQuntity = jobBll.GetMenuItemDayUsage(menuItemFK, reportFrom, reportTo, "Saturday", true);

    ParameterDiscreteValue parameterDiscreteValue = new ParameterDiscreteValue();
    if (dtQuntity.Rows[0][0].ToString() != "")
        parameterDiscreteValue.Value = dtQuntity.Rows[0][0].ToString();
    else
        parameterDiscreteValue.Value = "0";

    paramQuantity.Add(parameterDiscreteValue);

}
#endregion



//cr.SetParameterValue("Sunday Quantity", paramQuantity, "MenuReport");
//cr.SetParameterValue("Monday Quantity", paramQuantity, "MenuReport");
//cr.SetParameterValue("Tuesday Quantity", paramQuantity, "MenuReport");
//cr.SetParameterValue("Wednesday Quantity", paramQuantity, "MenuReport");
//cr.SetParameterValue("Thursday Quantity", paramQuantity, "MenuReport");
//cr.SetParameterValue("Friday Quantity", paramQuantity, "MenuReport");
cr.SetParameterValue("saturdayQuantity", paramQuantity, "MenuReport");

crvReport.ReportSource = cr;     
crvReport.RefreshReport();

Please help me as soon as possible.
waiting for replies.
thanks.