Skip to Content
avatar image
Former Member

Validation .. Help Please

Hi,

I have a situation where there are 2 fields..

Cost center Type

Site Name

Site name should be null(no value init) if the cost center type is 01 or 04 or 05 or 06 or 07 or 08 or 12.

So, in detail ...there should be a warning or error message when there is a value in Site name when cost center type is 01/04...

Please be advised that we should not write blank in the site name, the validation should not allow the entry thats it..no clearing of site name if condition is satisfied..

Did any one faced a similar situation, does anyone know how to code it in validation tab, i tried sevral options but ended up with out result..

KR

John

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

1 Answer

  • Best Answer
    avatar image
    Former Member
    Jun 07, 2011 at 08:43 AM

    Hi John,

    Is your Cost centre Type field is a lookup field or a text?

    As i feel it will be defently a lookup field, then your validation code will be

    IF( HAS_ANY_VALUES(Cost centre type [Record], 
    Cost Centre Type [01],
    Cost Centre Type [04],
    Cost Centre Type [05],
    Cost Centre Type [06],
    Cost Centre Type [07],
    Cost Centre Type [08],
    Cost Centre Type [12]),IS_NULL(Site Name))

    This will help you in validating the Site name is blank or not for the above cost centre types.

    Note: Please select your lookup values from the Lookps menu in the validation expression editor.

    Hope the above code will solve your problem

    Let us know if you have any questions.

    Regrads

    Sowseel

    Edited by: sowseel pasumarthi on Jun 7, 2011 10:53 AM

    Add comment
    10|10000 characters needed characters exceeded