How to properly configure dependent variables?

Stimulsoft Reports.WEB discussion
Post Reply
lucasribsantos
Posts: 1
Joined: Tue Aug 25, 2015 5:53 pm

How to properly configure dependent variables?

Post by lucasribsantos »

I'm currently working on a report that makes use of dependent variables, but I can't seem to make it work properly. As an example, I'm using the Northwind database and creating Business Objects inside my ASP.NET MVC application, then loading a pre-designed .mrt file and feeding the BOs to it. Here's what I have done so far:

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);
    }
Here's my dictionary panel on the Designer application: http://i.stack.imgur.com/zAEZE.png

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.
HighAley
Posts: 8430
Joined: Wed Jun 08, 2011 7:40 am
Location: Stimulsoft Office

Re: How to properly configure dependent variables?

Post by HighAley »

Hello.

Unfortunately, Dependent variables does not support business objects now.
We will let you know if there will be any changes.

Thank you.
HighAley
Posts: 8430
Joined: Wed Jun 08, 2011 7:40 am
Location: Stimulsoft Office

Re: How to properly configure dependent variables?

Post by HighAley »

Hello.

We are sorry to inform you that dependent variables feature could not be implemented for business objects.
Due to structure of data it's impossible to do because there is no relations in BO.

Thank you.
Post Reply