Code: Select all
public ActionResult GetDependentVariablesSnapshot()
{
string reportFile = Server.MapPath("~/bin/DependentVariables.mrt");
StiReport report = new StiReport();
report.Load(reportFile);
var reportBO = new DependentVariables();
var BOs = new List<StiBusinessObjectData>();
BOs.Add(new StiBusinessObjectData("", "DependentVariables", reportBO));
report.RegBusinessObject(BOs);
report.Dictionary.SynchronizeBusinessObjects();
return StiMvcViewer.GetReportSnapshotResult(report);
}
And here's the configuration for both variables (Category and Product): http://i.stack.imgur.com/dbT7H.png
I tested it and the Business Objects are correctly mapped, and the data is displayed. However, in the parameters form at the top of the report, while the "Category" select is correctly filled, the "Product" one shows all of the products, and it keeps the same even if I change the value of the "Category" select. I guess I might have misconfigured something, but I'm not sure what.