Bookshelf Home | Contents | Index | PDF |
Siebel Object Interfaces Reference > Interfaces Reference > Business Component Methods > GetFormattedFieldValue MethodGetFormattedFieldValue returns the field value in the current local format; it returns values in the same format as the Siebel UI. SyntaxBusComp.GetFormattedFieldValue(FieldName) ReturnsA string containing the value of the requested field, in the same format as displayed in the user interface, or an empty string ("") if the field is inactive or empty. UsageGetFormattedFieldValue is useful for code that is used in multiple countries with different formats for currency, date, and number. This method can be used only on fields that have been activated using ActivateField. Some special behavior is associated with particular data types. DTYPE_PHONE. When used on fields of DTYPE_PHONE, these methods return formatted phone numbers.
DTYPE_DATE. When used on fields of DTYPE_DATE, these methods are the same as GetFieldValue and SetFieldValue, except that the result is in the format of the Regional Setting. Table 20 shows the standard formats used by GetFieldValue and SetFieldValue to return data. If you attempt to use SetFieldValue and your Regional Setting format is different, you receive an error like this:
This error can be avoided by using the GetFormattedFieldValue and SetFormattedFieldValue methods. Used WithBrowser Script, COM Data Control, COM Data Server, Java Data Bean, Mobile Web Client Automation Server, Server Script ExampleThe following Siebel VB example demonstrates how to use the GetFormattedFieldValue function and how to calculate the number of days between two dates. Sub Button_Click See AlsoActivateField Method |
Siebel Object Interfaces Reference |