Style property: Field class
Description
Use the Style property to override the style class specified in Application Designer (on the Record tab of the page field properties) as a string value. The override style class can be a PeopleTools built-in style class or from a custom style sheet attached to the page.
Note:
While this property is read/write, you cannot use this property to return the value specified in Application Designer; this property returns a blank string unless it has been explicitly set in PeopleCode.
While this property overrides the style class specified in Application Designer, these system conditions will override the style class specified by this property:
-
If the field has an error, the field will be rendered using the PSERROR style class.
-
If the user has enabled multi-language entry and the field is language sensitive, the field will be rendered using the PSMULTILANG style class.
This property is read/write.
Example
Local Field &field;
&field = GetField();
If &field.Value = 1 Then;
&field.Style = "MY_STYLE1";
End-If;
If &field.Value = 2 Then;
&field.Style = "MY_STYLE2";
End-If;