Hello!
Its probably a very easy thing but i can´t find a solution to it.
I have a text field with 4 lines. The data comes from a SQL query.
Like
{Text0}
{Text1}
{Text2}
{Text3}
Sometimese some of those Texts are null or "". I want to remove the line break.
Like if Text1 is null i want it to output that way
{Text0}
{Text2}
{Text3}
So there is no empty line. It can happen for every line.
I played with IIF, <br> logic and can grow/shrink settings. Nothing works.
Thank you in advance!
Text, remove newlines for empty lines.
-
- Posts: 12
- Joined: Fri Jan 17, 2020 3:02 pm
-
- Posts: 6245
- Joined: Tue Mar 20, 2018 5:34 am
Re: Text, remove newlines for empty lines.
Hello,
Depends on the report structure. You can place each text in separate Text components and set the CanShrink=true, DockStyle=Top. Or place it on different ChildBands.
Thank you.
Depends on the report structure. You can place each text in separate Text components and set the CanShrink=true, DockStyle=Top. Or place it on different ChildBands.
Thank you.
-
- Posts: 12
- Joined: Fri Jan 17, 2020 3:02 pm
Re: Text, remove newlines for empty lines.
Hello,
thank you for the answer!
My problem is that i cant use dockstyle because there are some text components positioned at the same line in the databand.
Sadly i have no idea how to use ChildBands in this constelation and there are 6 text components in very cramped space and 2 of them should shrink while one has 4 possible lines and the other has 2. And the relative position of all elements should be maintained.
I solved it by using concat in the sql command and inserting HTML tags (<br>, <i> and </i>) at the necessarey spots and set the field to interpret HTML tags.
thank you for the answer!
My problem is that i cant use dockstyle because there are some text components positioned at the same line in the databand.
Sadly i have no idea how to use ChildBands in this constelation and there are 6 text components in very cramped space and 2 of them should shrink while one has 4 possible lines and the other has 2. And the relative position of all elements should be maintained.
I solved it by using concat in the sql command and inserting HTML tags (<br>, <i> and </i>) at the necessarey spots and set the field to interpret HTML tags.
-
- Posts: 6245
- Joined: Tue Mar 20, 2018 5:34 am
Re: Text, remove newlines for empty lines.
Hello,
Thank you for the information.
Thank you for the information.