Not able to embed custom font in PDF in C# application

Posted by: adika.singhvi on 3 February 2021, 5:52 am EST

    • Post Options:
    • Link

    Posted 3 February 2021, 5:52 am EST

    Hi,

    I am trying to use the below solution to embed few custom fonts but it does not seems to work.

    http://help.grapecity.com/activereports/webhelp/AR11/webframe.html#PDFCustomFontFactory.html

    Active Reports Version : 11.0.8705.0

    Edition : Professional

    Application Type: C# console application

    Environment: Windows 10 / Windows Cell (windows server core 2019)

    I saw a similar question on the forum and tried using the sample provided there, but that also didn’t work as expected.

    https://www.grapecity.com/forums/ar-dev/embed-font-in-pdf-from-c-r

    I tried on a Windows 10 machine. As the application is not able to pick the font from custom Fonts folder, it uses the default font i.e. Microsoft Sans Serif.

    I modified the sample to check on few fonts. Attaching the same here, with the runtime screenshots confirming that the custom font is not getting picked. Am I missing something? Please suggest. Also, it would be helpful if you can share a working solution.

    FontFactoryTester.zip[img]https://gccontent.blob.core.windows.net/forum-uploads/file-cbb9eca7-4b31-4f50-878c-7e7f3cb93bda.png[/img][img]https://gccontent.blob.core.windows.net/forum-uploads/file-31144b87-53d1-4f6d-985c-ba715896cfc0.png[/img]

  • Posted 5 February 2021, 9:17 am EST

    So, looks like the expected font is rendered when I use the custom font solution with version 11.3.13058.0 but not with 11.0.8705.0. The professional edition license that I am using mentions version 11.3.13058.0. But are the licenses specific to even the minor versions, shouldn’t it be working with V11 irrespective of the minor version?

    Or is the feature not available in 11.0.8705.0?

    I need to use the custom font feature with V11.0.8705.0. Please suggest.

  • Posted 7 February 2021, 9:42 am EST

    Hello,

    V11.0.8705.0 is old version of AR11. I suggest you to use the 11.3.13058.0 if it is working fine with this version.

    Also, Please note that AR11 is a legacy product now. It is out of maintenance mode now. Hence, we do not provide support for the same or no bug fixing will be done in the same. I would recommend you use the latest version of ActiveReports i.e ActiveReports 15.

    Please refer to the following link for more information:

    https://www.grapecity.com/activereports.

    Thanks,

    Mohit

  • Posted 8 February 2021, 12:41 am EST

    We are using V11.0.8705.0 from quite some time. We would not like to upgrade until there is a need of it.

    Are you saying that V11.0.8705.0 does not support custom fonts? Because as per the documentation, this feature was even available as part of AR 9. So, it should be there in AR 11.

    Then why this difference in behavior? Is it due to the license or there is a bug? I mean is the license tagged to a full version (v11.0.8705.0) or a major version (v11).

  • Posted 9 February 2021, 5:26 am EST

    Hello,

    May be there is bug in the old version of AR11, that’s why I suggest you to upgrade to the AR11 latest version. There is no breaking change between these version. Therefore, you only need to replace the AR11 dll with new one. You don’t have to change anything in code. Also, the license tagged to a full version a major version (v11). You can upgrade with the without buying the new license.

    Thanks,

    Mohit

Need extra support?

Upgrade your support plan and get personal unlimited phone support with our customer engagement team

Learn More

Forum Channels