I am trying to use HTML to align text on a Label so that some of it aligns to the left and some of it aligns to the right, on the same line. In here HTML in Vision) it says "most common HTML elements that you can use within Ignition", so I guess it's not an exhaustive list. I've tried some HTML stuff I found online, but to no avail. I also don't know if I can implement the solutions involving CSS.
The outcome I want is someting like this:
|This text is left aligned...........................................................This text is right aligned|
(without the dots of course)
My guess is that the property "Horizontal Alignment" in the Layout tab of the label's properties overwrites whatever HTML conflicts with it.
No CSS in Vision, that is only for Perspective. Why not use two separate labels? You could also use a one-line table without headers maybe.
There are multiples of that label on the same window and I don't want to have that many components. What I ended up doing is indeed two seperate labels with the same dimensions alligned on top of each other and grouped together. One with text alligned to the left and the other to the right.
He's on vision though.
That's pretty much exactly the solution that was suggested !
Another way of doing this that would not add components to the window is to abstract the two labels into a template.
Then you just have to repeat the template as many times as needed, passing it the two strings you want displayed.
edit: The table solution is also one to consider, particularly if your data is in a dataset.
Yes, this was my original plan if I couldn't figure out how to do what I asked, but I read the replies on Monday morning
Your suggestion sounds good also, you do end up with less components.
I'm gonna try the table one and revert.