Using the Barcode Fonts with Microsoft Excel Custom Functions

It's worth noting that ConnectCode Barcode Fonts and Software started out as a package to help users generate barcodes using fonts in Excel many years ago. The first version of ConnectCode comes with an Excel Add-In, and this is followed by the popular barcode formulas in Microsoft VBA. Many organizations quickly recognize the compelling advantages of using fonts to generate barcodes in Excel and this has led to the rise in adoption and popularity of ConnectCode's package. A barcode generated using fonts rasters to the resolution of the printer and is not limited to the DPI (Dots per Inch) of the computer screen. This ensures barcodes are of the highest quality and meet the strictest requirements of the auto-id industry.

The Add-In and VBA formulas have since been constantly upgraded to keep up with the fast-changing auto-id industry. Over the years, Microsoft has started providing Excel in different platforms such as Mac and the online Web. In these platforms, Microsoft needed a way for developers to provide custom Excel formulas in cross-platform manner. This has led to the introduction of Microsoft Excel Custom Functions which was officially released in 2019.

Microsoft and Excel are trademarks or registered trademarks of Microsoft Corporation in the United States and/or other countries.

Microsoft Excel Custom Functions
Microsoft Excel Custom Functions enable developers to add new functions that can be used on Excel running on different platforms such as Windows, Mac and Online. The Custom Functions are defined in JavaScript and can easily be accessed by users within Excel on their multiple devices running on different platforms.

Generate industry compliant barcodes with Excel Custom Functions
The latest version of ConnectCode comes with a complete set of Microsoft Excel Custom Functions for barcode generation using fonts. The Custom Functions assist users in creating industry compliant barcodes by generating check characters, adding start/stop characters, validating input characters, ensuring compliance with industry specifications, and also generating Human Readable Text that commonly appears below a barcode.

Tutorial on using the Barcode Fonts with ConnectCode's Custom Functions for Excel

This tutorial illustrates the setup and use of ConnectCode's Custom Functions with Office Excel Online to create a Code 128 A barcode. Please check out ConnectCode's Excel Custom Functions List for all other barcodes that are supported.

Important Notes

At this moment, Excel Online does not support setting of a local font for a cell in the worksheet. We will need to copy the output to Word Online to apply our barcode font to display the barcode. The extra steps required to copy the output from Excel Online to Word Online is illustrated at the end of the tutorial.


  • Microsoft Excel Online (The current version of ConnectCode's Custom Functions only supports Excel Online.)
  • ConnectCode Barcode Fonts and Software
1. Launch Microsoft Excel and create a new Workbook. Please ensure that you are using a supported version of Excel specified in the prerequisite section.

2. Download a copy of the manifest.xml from our website. In Excel, click on the "Insert" tab, and select "Office Add-Ins". Next, click on "Manage My Add-ins -> Upload My Add-In" and then select the downloaded "manifest.xml" file.

3. Enter the input data to be generated as barcodes in column A as shown below. In cell "B2", enter "CONNECTCODE." to see the list of available custom functions. Functions ending "...HRT" are used to generate the Human Readable Text that commonly appear below a barcode. All other functions are used for generating barcodes. In the screenshot below, we have selected the "=CONNECTCODE.ENCODE_CODE128A" function to generate a Code 128 Subset A barcode.

In the following function,


"CONNECTCODE" is our company name and is used to group all the Custom Barcode Functions we provide. "ENCODE_CODE128A" is the Custom Function we provide to generate a Code 128 Subset A barcode and cell A2 contains the input data for this barcode. You can also enter the input data as a string, such as "12345678" directly in the formula. For some barcodes such as Code 39, you can specify a second parameter "1" to turn on or "0" to turn off the optional check digit. For example, the following Custom Function generates a Code 39 barcode without a check digit:


4. Next, please launch Word Online, create a new Word document and copy the output in cell B2 from the Excel worksheet and paste it into the new Word document.

5. Select the output and set the Font to "CCode128_S3" (or "CCode128_S3_Trial" if you are using the Trial version) and set the Font Size to "24". You should see the following Code 128 Subset A barcode. During the selection of the output for setting of the font, be careful not to select/include the "hidden" and automatically generated end of line character of Word.

With the steps above, you have created a high-quality Code 128 A barcode that complies to the strictest requirements of the auto-id industry. To generate other barcodes, please see the
List of ConnectCode's Excel Custom Functions.