function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
mahi1mahi1 

Need trigger for text field to accept only numbers

hi,
i created a custom Text filed (Pincode__c) , I need to write a trigger for this field to accept only numbers
Vinit_KumarVinit_Kumar
Any reason you need a Trigger for this,you can have a number field in place of Text field. 
Ramu_SFDCRamu_SFDC
Hi Mahi, The following two posts have two different scenario's and solutions hope they will help you

 https://success.salesforce.com/answers?id=90630000000girwAAA

https://success.salesforce.com/answers?id=90630000000gr1GAAQ