Page 1 of 1

How to initialize a variable from a form field

Posted: Mon Dec 05, 2016 9:55 am
by pflores
Hello,

I declared a variable in my report, and I have a form that shows up before the report is rendered.

I'd like the variable to be set to the value the user wrote in my form.
I tried to init the variable with the expression "myFormField.Text" but it gives me an error.

Is there a way to do what I want?
Thanks.

Re: How to initialize a variable from a form field

Posted: Tue Dec 06, 2016 8:29 pm
by Alex K.
Hello,

Could you explain your issue in more details?
Also, please send us a simple report which reproduces the issue for analysis.

Thank you.

Re: How to initialize a variable from a form field

Posted: Wed Dec 07, 2016 3:20 pm
by pflores
I upload an example report.

I try to set a variable "myVariable" to the value of the name field in the form, but i get an error (that I cannot display) in the preview.

Re: How to initialize a variable from a form field

Posted: Thu Dec 08, 2016 7:46 am
by Alex K.
Hello,

In this case, try to set the ReadOnly property for the variable.

Thank you.