Page 1 of 1

Change the size of text field if the data does not exist

Posted: Sat Sep 16, 2023 1:19 pm
by Maria_Vaht
Hello!

Here I have DataBand with text fields inside. I would like to do the next: the text field which displays MAIN.SEC_PRICE_LAST (yellow) should be hidden if MAIN.SEC_PRICE_LAST is null. Also the height of text field which shows MAIN.SEC_PRICE_FIRST (green) should be stretched to the height of DataBand.
Image

This is how the result looks like now:
Image

The left result is okay but in case when MAIN.SEC_PRICE_LAST is null I would like the report to look as follows:
Image

I would appreciate any assistance. Thank you!

Re: Change the size of text field if the data does not exist

Posted: Mon Sep 18, 2023 10:47 am
by Lech Kulikowski
Hello,

Please send us a sample report with test data that reproduces the issue for analysis.

Thank you.

Re: Change the size of text field if the data does not exist

Posted: Mon Sep 18, 2023 12:08 pm
by Maria_Vaht
Lech Kulikowski wrote: Mon Sep 18, 2023 10:47 am Hello,

Please send us a sample report with test data that reproduces the issue for analysis.

Thank you.
REPORT_REG_OTHER_OPER support.mrt
(21.43 KiB) Downloaded 180 times

Re: Change the size of text field if the data does not exist

Posted: Mon Sep 18, 2023 8:47 pm
by Lech Kulikowski
Hello,

> the text field which displays MAIN.SEC_PRICE_LAST (yellow) should be hidden if MAIN.SEC_PRICE_LAST is null.

You can use the expression for the Enabled property:
MAIN.SEC_PRICE_LAST != ""

> Also the height of text field which shows MAIN.SEC_PRICE_FIRST (green) should be stretched to the height of DataBand.

You can set the GrowToHeight property for the MAIN.SEC_PRICE_FIRST text component.

Thank you.

Re: Change the size of text field if the data does not exist

Posted: Tue Sep 19, 2023 12:20 pm
by Maria_Vaht
Lech Kulikowski wrote: Mon Sep 18, 2023 8:47 pm Hello,

> the text field which displays MAIN.SEC_PRICE_LAST (yellow) should be hidden if MAIN.SEC_PRICE_LAST is null.

You can use the expression for the Enabled property:
MAIN.SEC_PRICE_LAST != ""

> Also the height of text field which shows MAIN.SEC_PRICE_FIRST (green) should be stretched to the height of DataBand.

You can set the GrowToHeight property for the MAIN.SEC_PRICE_FIRST text component.

Thank you.
Thank you very much, I solved it! :)

Re: Change the size of text field if the data does not exist

Posted: Tue Sep 19, 2023 1:38 pm
by Lech Kulikowski
Hello,

You are welcome.