RasmusTidselbak / al-var-helper

6 stars 6 forks source link

Remove Numbers or dots at beginning of variable name #25

Open f4n0 opened 4 years ago

f4n0 commented 4 years ago

Hi, I have objects names like that "" like "EOS001 Customer List". when using the variable snippet it will successfully trim the prefix but obviously not the AppCode. unfortunately, the AL compiler will throw this error: ' 001 .' is not valid value in this context.AL(AL0519)

using this regex, it will trim the digits or dots at the beginning of a string, and it will create a compliant variable name /^(\d|\.)+/gm