Configuring Siebel Business Applications > Configuring Business Components, Links, and Business Objects > Customizing a Business Component Field >

Validating Data That the User Enters In a Business Component Field

You can configure Siebel CRM to validate the information that the user enters into a field. You can configure the error message that Siebel CRM displays if the user enters information that does not meet the validation expression.

To validate data that the user enters in a business component field

  1. Make sure Siebel Tools is configured to allow you to modify a text string.

    For more information, see Setting Up the Configuration File for Siebel Tools.

  2. Create the symbolic strings that Siebel CRM displays for the error message.
  3. In the Object Explorer, click Business Component.
  4. In the Business Components list, locate the business component that contains the field for which you must configure validation.
  5. In the Object Explorer, click Field.
  6. In the Fields list, locate the field for which you must configure validation.
  7. In the Validation property, enter an expression that performs the desired validation.

    You can use the Expression Builder to build the expression. To display the Expression Builder, click ellipsis (...) in the Validation property.

  8. In the Validation Error Message - String Reference property, enter the name of the symbolic string you created in Step 2 for this error message.

    As an alternative, you can use the Validation Message property to enter the error message without using a symbolic string. You can also use the Validation Message - String Override property to override the error message.

  9. In the Message Display Mode property, choose one of the following display modes for the error message:
    • User Msg. Displays only the error message that you provide.
    • User Msg with Error Code Only. Displays the error message that you provide along with the system error code.
    • User Msg with Error Code/Msg. Displays the error message that you provide along with the system error code and the system error message.
  10. Compile and test your changes.

    For more information, see Using Siebel Tools.

How Siebel CRM Validates Start and End Dates

If the user sets the completion date for an activity to occur before the start date for the activity, then Siebel CRM displays an error that is similar to the following:

Wrong field values or value types detected in field End.

Siebel CRM ignores any configuration you define in the Validation property or the Validation Message property for these date fields. For example, assume the user navigates to the Activities screen, clicks Activity List, and then sets the value in the Start field to a date that is later than the value in the End field. This Start field references the Planned field of the Action business component. If you define a value in the Validation property or the Validation Message property for the Planned field, then Siebel CRM ignores it. Instead, Siebel CRM uses one of the following specialized classes in the Action business component to perform this validation:

  • CSSBCActivity for Siebel CRM version 8 of Siebel Business Applications.
  • CSSBCFINSActivity Siebel CRM version 8 of Siebel Industry Applications. The parent class is CSSBCActivity.

Although you cannot configure the predefined validation in the classes, you can add script in the BusComp_PreSetFieldValue event for the business component. This script monitors updates to these fields, and then compares the field values. You can also write a custom error message in this script. For more information, see the topic about the CSSBCActivity class in Siebel Developer's Reference.

Configuring Siebel Business Applications Copyright © 2011, Oracle and/or its affiliates. All rights reserved. Legal Notices.