0

I want to apply a validation rule for a price__c (data type is currency).My condition is that in remote app creation this field accept alphabet as a input and after click on save button it save only number in this field ,Now i want that if a user gave the input as alphabet it show error at this time how can i achieve this ? I am trying NOT(REGEX(TEXT(Price__c), '^[0-9;]*')) but its not working.

4
  • If your Price__c is Currency - then it wont accept any other characters than numbers to store in it by default. – Salesforce Steps Oct 6 '15 at 12:40
  • When i take input as character in accept the input but save only number so now my requirement is that at the time of user give the character as input it show error message – sheetal Oct 6 '15 at 12:44
  • Your are trying get value for this field on VF ? if yes then try JavaScript Validation in VF page code itself. – Salesforce Steps Oct 6 '15 at 12:46
0

If your Price__c is Currency - then it wont accept any other characters than numbers to store in it by default.

May be this is cause (not sure) - But if you are using it somewhere else than Standard UI ---then try validation rule like this -

NOT( ISNUMBER(TEXT(Price__c) ) )

1
  • Its not working in mobile (remote app) – sheetal Oct 6 '15 at 12:51

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.