Text field warp inside template

Hi ,
I have a text field inside template , this text field have property binding with SQL query to retrieve a description .
how can i make warp for result of this query
query
SELECT Description FROM c1dtcode where DT_Code =“Machinecode”

In what way do you want it to warp? Do you want the text box to get bigger depending on the amount of text? Or do you want the text to go on to more than one line?

I may be reading this as word wrap. If so, you can’t wrap a Text Field. Consider using a Text Area instead.

Hi Jonathan , thanks for your reply
Yes, i am using label as text display for the query result . i want the text to go on to more than one line .
@JordanCClark
thanks for you inpunt.
i i want the text to go on to more than one line. i am using label.
i you have recommendation please specify .

Thanks
Tamer

Hi tamer,

For a label, you can word wrap by using an html prefix.

<html>Some text that needs to be wrapped. Because we like things that are easy to read without effort.

1 Like

Hi Jordan
Thanks for your support .it’s seam i didn’t clarify my question in proper way .
i have text label binding in sql query . query result is a text which i need to warp .
Select Description from Sideldowntime where code ={PETMachineData.Downtime} and Equipmenet="{PETMachineData.MachineName}"

the result length is not fixed based on description .

Use text area instead of a text field. Or move your binding to a custom string property, then use an expression to add <html> to the beginning of the description.

1 Like

for more clarification

Either limit the description length in the database to match your available gui space, increase the vertical GUI space to accommodate line-wrapping as described above, or dynamically change the font size based on the number of characters to display.

1 Like

Thank a lot @pturmel it working as per your recommendation . String Property >> Added with expression .

this the power of Ignition different way to do the work :slight_smile: