Hi All.
Is possible to change color only horizontal edges for TextFields by condition in JavaScript?
Thanks.
Solved! Go to Solution.
Views
Replies
Total Likes
Hi,
Assuming you are talking about the border around the UI part of the text field (not the border around the while widget) and you have already set the border style to one of the ones what allows colors (not one of the 3D styles) then you can use this code to set the top and bottom border colors (in this case to red)
var topBorderEdge = TextField1.ui.oneOfChild.border.getElement("edge", 0);
var bottomBorderEdge = TextField1.ui.oneOfChild.border.getElement("edge", 2);
topBorderEdge.color.value = "255,0,0"
bottomBorderEdge.color.value = "255,0,0"
Regards
Bruce
Views
Replies
Total Likes
Hi,
Assuming you are talking about the border around the UI part of the text field (not the border around the while widget) and you have already set the border style to one of the ones what allows colors (not one of the 3D styles) then you can use this code to set the top and bottom border colors (in this case to red)
var topBorderEdge = TextField1.ui.oneOfChild.border.getElement("edge", 0);
var bottomBorderEdge = TextField1.ui.oneOfChild.border.getElement("edge", 2);
topBorderEdge.color.value = "255,0,0"
bottomBorderEdge.color.value = "255,0,0"
Regards
Bruce
Views
Replies
Total Likes
Thanks.
Views
Replies
Total Likes
Views
Likes
Replies
Views
Likes
Replies
Views
Likes
Replies