0

I have a combobox with list of customers, when choose a specific customer and make a query and send it to stimulsoft to create a report, it works correctly, but when I close the report and choose another customer the report still show the previous customer's report并且不更新它。
直到我关闭表单并重新打开它,然后选择其他客户,但是当我选择其他客户时,它再次无法正常工作。

var results = (from x in asdb.TblCustomers
                           where x.CustID == (int)rddCustName.SelectedValue
                           select x).ToList();

            stiSpecCust.Load("Reports//SpecCustM.mrt");
            stiSpecCust.RegBusinessObject("DT", "DT", results);
            stiSpecCust.Render();
            stiSpecCust.Show();
4

2 回答 2

1

我找到了解决方案:

我们必须在 RegBusinessObject 之前添加它:

stiSpecCust.BusinessObjectsStore.Clear();
于 2013-08-03T19:44:36.650 回答
0

试试这个:在路径之后,参数会这样做

 stiSpecCust.Compile();
 stiSpecCust.Render();
 stiSpecCust.Show();

你需要在渲染之前编译

于 2017-04-30T05:00:17.403 回答