function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
NewGirlNewGirl 

Scaning barcode into SF - how to parse string into different fields

Hello All -

 

I need to scan a barcode into a salesforce screen.  How do I then break up the barcode string into different salesforce fields?

 

Thanks for you help!

 

ngabraningabrani

The Apex String class has many useful methods. These may be used to process your barcode string based upon requisite separator (or length of fields).

 

http://www.salesforce.com/us/developer/docs/apexcode/Content/apex_methods_system_string.htm

 

NewGirlNewGirl

I will know the length of the string so I realize I can use the substring function. 

 

However, once I scan the barcode into a field on my salesforce screen - I need to parse the string and populate other fields on the screen with the parsed barcode.  How do I do that?  Triggers are events on the table.  How do I know when a value has been scanned into a field on the screen??

 

Thanks for all your help!

KC