Dynamic varible from DataSource

Stimulsoft Reports.JS discussion
Post Reply
Mathaeusxs
Posts: 1
Joined: Mon Jul 15, 2019 2:11 pm

Dynamic varible from DataSource

Post by Mathaeusxs »

Hi,

im trying to set custom variable from DataSource JSON data. Im doing it by creating variable "TestVar" in Report. And then edit Before Print event expression in ReportTitleBand2 like:

Code: Select all

TestVar = "";
Customers.first();
while(!Customers.isEof)
{
	// PlaingToDoSomeIfLogic
	TestVar += Customers.ContactTitle + ',';
	Customers.next();
}
All i get is undefined variables... Idk what im doing wrong or it is possible to so something like that in Reports.JS ? I mean creating some dynamic variable by looping dataSet or just from dataSet column?

Stimulsoft.Reports.JS
Version: 2019.3.2
Build date: 2019.06.17
Angular 7

Adding example "TestVar.mrt".
Attachments
TestVar.mrt
(21.16 KiB) Downloaded 143 times
Lech Kulikowski
Posts: 7289
Joined: Tue Mar 20, 2018 5:34 am

Re: Dynamic varible from DataSource

Post by Lech Kulikowski »

Hello,

In the JS version is available only Interpretation mode which does not support code in events.

Thank you.
Post Reply