vb.net – 存储Crystal Report中当前行的上一行值
发布时间:2020-12-17 07:15:56 所属栏目:百科 来源:网络整理
导读:我想检索当前行中的上一行值,如下所示(Crystal Report 2008): +------------+-----------------+----------+------------+----------------+| Date | PreviousBalance | Loan | Collection | CurrentBalance |+============+=================+==========+=
我想检索当前行中的上一行值,如下所示(Crystal Report 2008):
+------------+-----------------+----------+------------+----------------+ | Date | PreviousBalance | Loan | Collection | CurrentBalance | +============+=================+==========+============+================| | 14/02/2012 | 00.00 | 10000.00 | 00.00 | 10,000.00 | | 15/02/2012 | 10,000.00 | 00.00 | 500.00 | 9,500.00 | | 16/02/2012 | 9,500.00 | 00.00 | 500.00 | 9,000.00 | | 18/02/2012 | 9,000.00 | 5,000.00 | 00.00 | 14,000.00 | +------------+-----------------+----------+------------+----------------+ 解决方法
这比看起来容易:
>为字段{table.Loan}创建两个Running Totals,一个用于Loan {#TLoan},为字段{table.Collection}创建一个Collection {#TCol}. {#TLoan} – {#} TCOL 这将具有CurrentBalance值. >创建另一个公式:{@Prev},其中包含以下内容: {@Total} – {table.Loan} {table.Collection} 这将具有PreviousBalance值. 使用这种方法不需要复杂的公式,结果是预期的. 希望能帮助到你! (编辑:李大同) 【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容! |