Welcome Guest Search | Active Topics | Sign In | Register

Custom AcmText Font when Using PDF Creator Options
ckmba
Posted: Monday, December 9, 2013 1:00:19 PM
Rank: Member
Groups: Member

Joined: 4/25/2013
Posts: 17
Greetings.

I would like to know how to use a custom font when creating a AcmText element using PDF Creator.

For example, I have a barcode font on my web server at the following location: "Custom_Font/Barcode_Font.TTF"

I would like to use the barcode font instead of the default font.

Thank you in Advance.

-chad
eo_support
Posted: Monday, December 9, 2013 1:06:57 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,196
Hi,

You would need to install the font on your system, then use Style.FontName to use the font:

http://www.essentialobjects.com/doc/4/eo.pdf.acm.acmstyle.fontname.aspx

Thanks!
ckmba
Posted: Monday, December 9, 2013 3:36:07 PM
Rank: Member
Groups: Member

Joined: 4/25/2013
Posts: 17
Thanks for the info. I was able to get it to work with other installed fonts but I can't get it to display with any barcode fonts. Do you have any suggestions?

Here is the font:

http://www.dafont.com/3of9-barcode.font


Here is my code:

Code: C#
//Create an ACM text object
AcmText Attendee_PIN = new AcmText("99001200");
Attendee_PIN.Style.FontName = "3 of 9 Barcode";
Attendee_PIN.Style.FontSize = 30f;
Attendee_PIN.Style.ForegroundColor = Color.Black;


I downloaded and installed several other barcode fonts and haven't had any luck yet. I'm able to see the fonts in Microsoft Word and render them in webpages so I know they work otherwise.

Any suggestions you could give would be very appreciated.

Thanks!
eo_support
Posted: Monday, December 9, 2013 3:50:40 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,196
Thanks for the additional information. We will look into this and get back to you as soon as possible.
ckmba
Posted: Monday, December 9, 2013 4:24:56 PM
Rank: Member
Groups: Member

Joined: 4/25/2013
Posts: 17
OK! I figured out the problem. After a bunch of testing I realized that the PDF wasn't displaying any fonts that weren't already in my system. Any new font that I installed (which most of which happened to be barcode fonts) wouldn't display. Once figuring this out I realized that it was probably my font cache. I went to Control Panel > Administration > Services > and started my "Windows Presentation Foundation Font Cache" service and rebooted. That fixed it!

FYI: I noticed that in my System32 folder the "FNTCACHE.DAT" file had a modify date of 1/1/2013 before I started the service and 12/9/2013 after I did (plus it was about 4 times larger).

Thanks for your help!
eo_support
Posted: Monday, December 9, 2013 10:16:01 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,196
Wow. We wouldn't have thought about that! Thank you very much for sharing!


You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.