Hi,
I've been creating an application for onboarding clients. For this I want to create an auto generated field in CDT. whenever a new client register for onboarding and successfully submits the form, automatically the unique onboarding number have to create for every client.
Is it possible to create?
Thanks in advance.
Discussion posts and replies are publicly visible
I use this function when generating a unique identifier.
a!localVariables( local!raw: a!refreshVariable( value: concat( dec2hex(toint(rand(4)*256),2), "-", dec2hex(toint(rand(2)*256),2), "-", dec2hex(toint(rand(2)*256),2), "-", dec2hex(toint(rand(2)*256),2), "-", dec2hex(datetext(now(),"yyyy"),3), dec2hex(datetext(now(),"MMdd"),3), dec2hex(datetext(now(),"HHmm"),3), dec2hex(datetext(now(),"SSss"),3) ), refreshAlways: true ), local!rawLength: len(local!raw), concat( a!forEach( items: 1 + enumerate(local!rawLength), expression: a!localVariables( local!currentCharacter: index( local!raw, fv!item, {} ), if( a!isNullOrEmpty( stripwith( lower(local!currentCharacter), "abcdefghijklmnopqkstuvwxyz" ) ), if( rand(1) < 0.5, lower(local!currentCharacter), local!currentCharacter ), local!currentCharacter ) ) ) ) )
Thank you for your valuable reply