Community

Flexicapture 11 How to pad a varchar field with leading zeros

I am new to Flexicapture. I have a customer id that needs to be 10 characters in length. On the pdf if it is not 10 characters, the image does not print the leading zeros. How can I add the leading zeros so it is in the correct format when I export to my ms sql database? I'm not sure if I create a rule or create a custom action.

Was this article helpful?

0 out of 0 found this helpful

Comments

2 comments

  • Avatar
    Alberto Torino
    Hello Darla,
    Assuming your field's type is text, you can add a rule script to the field in order to format it. In VB should be :
    If Len(Me.Text) < 10="" then="">
    Me.Text = String( 10 -Len (Me.Text),"0") & Me.Text
    End if

    Hope this helps.
    Kind regards,
    0
  • Avatar
    Permanently deleted user
    It worked. Thank you very much
    0

Please sign in to leave a comment.