Hi
I’m trying to create a bar-code from an item code im printing to screen
can this be done? and if so, how do I go about creating it in ColdFusion
Thanks
Damien
Hi
I’m trying to create a bar-code from an item code im printing to screen
can this be done? and if so, how do I go about creating it in ColdFusion
Thanks
Damien
A 5 minute Google found these for me -
http://www.riaforge.org/index.cfm?event=page.search#barcode
HTH
Cheers,
James
Hi James
I was googling and found the same myself, then I downloaded a font called “Free 3 of 9” from the web and its seems to work fine in notepad, but when I put it into coldfusion I cant get the font to appear any bigger,
heres my code:
<tr>
<td height="205px;">
<!--- Item Code --->
<font color="##000000" font size="70" face="Free 3 of 9">
#structheader.ITEM#
</td>
<td>
any tips?
ColdFusion would just create the HTML and push it to the browser. It’s up to the browser how it renders that result and displays.
I think if you take that approach though you’re going to end up with a headache. Basically anyone that wants to view the barcode is going to need that custom font installed on their browser. Chances of that happening is pretty unlikely
Things are getting better as more browsers are now starting to support custom fonts but a) You’re still not going to get everyone that way & b) you’ll never get that kind of support using a “dinosaur” tag called font
Change of approach - Why don’t you get ColdFusion to make a bar code image based on your text and output that to screen?
Have a look at - http://cfsearching.blogspot.com/2009/11/introduction-to-java-barbecue-library.html
Cheers,
James
ah
never thought of needing the font on all users machines, Thanks
I did try downloading the barbecue-1.5-beta1.jar earlier today from this website: http://ricardo.parente.us/2008/09/printing-barcode-from-coldfusion/ and followed the instructions but nothing happened, even after restarting coldfusion in the services
or maybe should I restart the actual server?
Weird! It should work on Service restart.
Have a look at your System Information in the ColdFusion Administration and see if it’s coming up in there under Java Class Path.
If all that fails then you could have a look at a tool called JavaLoader. It’s got me out a few sticky situations with Java and path problems in the past.
Yep its displaying in the system info
I’ll check out JavaLoader
Thanks for your help James
Cool then ColdFusion knows about it so it’s probably a path issue in your code somewhere
No problem and good luck with it
James
I just used a bar code font for my application and printed it out on a label printer.
You’ll also have to have your host install the bar code font on the server and make sure it registered in CF admin, otherwise you’ll still land up with a blank image, or plain text in the image, instead of the bar code when you want to generate the bar code in as an image or in a pdf.