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
Dave The RaveDave The Rave 

Regex code needs amending for Romanian telephone numbers

All,

I have inheritated some code from an old webform which is als web-to-case, however Regex code does not match the vallidation we now require.
 
^(\+4|)?(07[0-8]{1}[0-9]{1}|02[0-9]{2}|03[0-9]{2}){1}?(\s|\.|\-)?([0-9]{3}(\s|\.|\-|)){2}$

The above needs to accept spaces and 0040

e.g. +40 728 318 871

or 0040 728 318 871

Can anyone suggest what the code should be?

Thanks,

​​​​​​​Dave
VinayVinay (Salesforce Developers) 
Hi Dave,

Try below combinations.

https://www.geeksforgeeks.org/validating-roman-numerals-using-regular-expression/
https://regexr.com/39fv1

Thanks,