Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

This topic is 4125 days old. Please don't post here. Open a new topic instead.

Recommended Posts

  • Newbies
Posted

Special thanks to MatthewF for helping me get started.

 

I have form that will allow single input of serial numbers or allow for batch adding thanks to MatthewF

 

The problem is currently I am using a prefix number then adding it to a number (rNumber)+sNum  but I want the number part to be a defined length like 4 digits or 5 digits etc but if i have "0" in the rNumber it simply drops it or if it turns over it adds a digit.  (rNumber= 003 becomes 3 or rNumber= 999 becomes 1000 when incremented instead of 000)

 

current script in the calculated field is

Left (serialPrefix; Length (serialPrefix)  ) & Right (serialPrefix; 1) +rNumber+sNum

What I would like is if you put 0003 in the rNumber field it will recognize that the serial number is starting on  3 but that the number part needs to be 4 digits long

 

Sample serial number would look like this

UR12P13X0023

serialPrefix=UR12P13X

rNumber=0023

Serials master.zip

Posted

What about

 

Let(

num = rNumber +sNum;

serialPrefix & Right("00000" & num;$$numDigitsDesired)

)

 

Substituting your desired number of digits for $$numDigitsDesired.

This topic is 4125 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.