A new feature coming from SharePoint 2010 that you can add a barcode in your documents.
Barcode option coming as a content type information policy that you can enable it for any content type inherited from Document content type or inherited from any content type that inherit Document content type.
1- From site settings page click on site content types
2- Click on your content type that you need to enable barcode on it
3- Click on “information management policy settings
4- In the next page check the following options:
- Enable Barcodes.
- Prompt users to insert a barcode before saving or printing: this option will enforce the user to add a barcode in the document header before saving this document.
Then click ok.
5- After enabling the feature, you have to modify the view of the library.
Go to the library you want to display the barcode in, and select library from the ribbon on the top.
6- Look for the barcode column and check it. Then click ok.
7- Add a document to the library and the barcode will appear as follows.