HtmlText is defined as any rendered text in a Web application that does not belong to any other Html class, that is, is not a list, link, table, or heading.
In addition to the properties it inherits from the AnyWin class and the Control class, HtmlText has the following properties:
Property | Type | Description |
---|---|---|
$BackColor | STRING | Background color: the name of the color if it matches one of the colors in the Table of Colors of Silk Test Classic; otherwise an RGB value (red, green, blue). |
$Caption | STRING | The text, up to 255 characters. For more information, see the GetCaption function. |
$FontName | STRING | Font name |
$FontSize | INTEGER | Font size in points |
$FontStyle | FONTSTYLE | Font style |
$FullCaption | STRING | The full text (up to a maximum of 255 characters). For more information, see the GetFullCaption function; note that the GetFullCaption function returns up to 1023 characters. |
$MultiText | LIST OF STRING | The full text, with line endings as displayed in browser. For more information, see GetMultiText function (HtmlHeading, HtmlLink, HtmlText) |
$Text | STRING | The first line of text, up to a maximum of 255 characters. For more information, see the GetText function. Note that the GetText function returns up to 1024 characters. |
$TextColor | STRING | Text color: the name of the color if it matches one of the colors in the Table of Colors of Silk Test Classic; otherwise an RGB value (red, green, blue). |
$WrappedText | LIST OF STRING | The full text, with text wrapped at 64 characters per string. For more information, see the GetWrappedText function. |
The properties $BackColor, $FontName, $FontSize, $FontStyle, and $TextColor apply to the first character, first line of the entire text object. Use the GetProperty function to access these properties for the first character of the text object.
To get the properties of a specified position within the text object, use the GetTextProp function.
For more information, see About properties.
A text object less than 65 characters is considered static and can be used to tag other objects (as long as it is not numeric).
By default, Silk Test Classic issues API clicks instead of Agent-based clicks for HtmlText with the Click method. See API click versus Agent click for more information.