adding two values from two textboxes
-
- Posts: 52
- Joined: Wed May 17, 2017 10:14 pm
Re: adding two values from two textboxes
How do I write this so it will work with c# script? It was written with vb as the scripting engine. When I try to use the & operator in place of the AND it fails. How can I write it so c# will understand it?
SumIf(DataBand1,QueryResults.Invoice_Transaction_Gross_Amount,QueryResults.Invoice_Transaction_Charge_Code_Description="Property & Casualty Premium"
AND QueryResults.Invoice_Production_Reporting_Date>=VI2
AND QueryResults.Invoice_Production_Reporting_Date<=VI3
)
SumIf(DataBand1,QueryResults.Invoice_Transaction_Gross_Amount,QueryResults.Invoice_Transaction_Charge_Code_Description="Property & Casualty Premium"
AND QueryResults.Invoice_Production_Reporting_Date>=VI2
AND QueryResults.Invoice_Production_Reporting_Date<=VI3
)
-
- Posts: 6254
- Joined: Tue Mar 20, 2018 5:34 am
Re: adding two values from two textboxes
Hello,
Please check what language you are using - VB or CSharp, and use correct operators.
Thank you.
Please check what language you are using - VB or CSharp, and use correct operators.
Thank you.
-
- Posts: 52
- Joined: Wed May 17, 2017 10:14 pm
Re: adding two values from two textboxes
Thanks for your answers. I finally figured that out on my own.
-
- Posts: 6254
- Joined: Tue Mar 20, 2018 5:34 am
Re: adding two values from two textboxes
Hello,
You are welcome.
You are welcome.
-
- Posts: 52
- Joined: Wed May 17, 2017 10:14 pm
Re: adding two values from two textboxes
I tried to mimic what you showed in your sample report, but now I am getting the following. What could possibly cause this?
I am using data from SQL Server. You are using xml. Could this be the problem?
On the first page the VB2 variable in the textbox doesn't present the value returned from the expression. It just shows the value 0
On the second page the returned value of the expression on the first page shows instead of what should be the returned value from the expression on the second
page.
I am using data from SQL Server. You are using xml. Could this be the problem?
On the first page the VB2 variable in the textbox doesn't present the value returned from the expression. It just shows the value 0
On the second page the returned value of the expression on the first page shows instead of what should be the returned value from the expression on the second
page.
-
- Posts: 6254
- Joined: Tue Mar 20, 2018 5:34 am
Re: adding two values from two textboxes
Hello,
Please send your report for analysis.
Thank you.
Please send your report for analysis.
Thank you.
-
- Posts: 52
- Joined: Wed May 17, 2017 10:14 pm
Re: adding two values from two textboxes
Here you go. Thank you!
- Attachments
-
- Compensation Report 1.mrt
- (20.56 KiB) Downloaded 67 times
-
- Posts: 6254
- Joined: Tue Mar 20, 2018 5:34 am
Re: adding two values from two textboxes
Hello,
Please check that this component is higher in the Report tree.
Thank you.
Please check that this component is higher in the Report tree.
Thank you.
- Attachments
-
- Screenshot 2023-01-03 090639.png (52.48 KiB) Viewed 790 times
-
- Posts: 52
- Joined: Wed May 17, 2017 10:14 pm
Re: adding two values from two textboxes
It doesn't work no matter what order the components are in.