Jump to content

128 C Barcode


Fletch

Recommended Posts

Hello fellow creators. The company I work for has a customer insisting that we create a 128 C barcode in order to be eligible for a big job. I see where there are rules built-in to Creator for 128 and 128 B. Is there a way to create a 128 C?
Link to comment
Share on other sites

I m going to add some specifics to this. I understand that the 128 bar code will automatically switch between A,B and C to give the best possible bar code. What we need is a rule that will fail if a set number of digits are not present (like on a UPC code) and if there are any 'Alpha' or 'Special' characters (non-numerical) in the data. I know we can verify all this in the data before ever getting to FP, but our customer is telling us that our competition is able to do this. ( I have my doubts, but I don't know everything) So, can a rule be made to verify the contents of a record are numeric only and have a set number of characters?
Link to comment
Share on other sites

I m going to add some specifics to this. I understand that the 128 bar code will automatically switch between A,B and C to give the best possible bar code. What we need is a rule that will fail if a set number of digits are not present (like on a UPC code) and if there are any 'Alpha' or 'Special' characters (non-numerical) in the data. I know we can verify all this in the data before ever getting to FP, but our customer is telling us that our competition is able to do this. ( I have my doubts, but I don't know everything) So, can a rule be made to verify the contents of a record are numeric only and have a set number of characters?

Well, I'm not sure what the "set number of digits" are for your requirement, nor exactly how you want the rule to fail, but yeah, JavaScript is great for that kind of input validation:

var s = Field("YourFieldName");
if (s.match(/\D/) || s.length != 12) // <- or whatever length you want to enforce
   return '<span color=Red>Error: Barcode data must be 12 numeric digits!</span>';
//else    
return '<span font="IDAutomationC128M">' + TaggedFromRaw(Make128Barcode(s)) + '</span>';

Link to comment
Share on other sites

Here's the message I get when I run the rule. The field has 30 numerals in it, so I changed the number in the rule from 12 to 30 in both places. I also inserted the field name.

 

Word <font=> does not fit in frame after line 1.

The amount of text inserted into a flow exceeds the depth

of all frames in the flow <>. Text is truncated.

Text does not fit in the last frame on page 1 at (0.30, 0.11).

Job ended 13:47:15 - 1486147635.

Total Job Time: 1s

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...