Dynamically changing characterset of template fields

Knowledge exchange related to the VPE Report Engine and PDF Library

Moderator: IDEAL Software Support

Dynamically changing characterset of template fields

Postby bemsofpe » Mon Nov 17, 2008 3:40 pm

Hi,

I'm upgrading our application to use unicode fonts, so to print using VPE we need to convert these unicode characters back to ansi characters and choose the correct character set in VPE. This works well for VPE itself, but I am looking to do the same for our dycodoc template based layouts. Here we have to specify the character set in Dydoco while creating the layout, but at that time we do not know which character set we will use when printing.
Some further explanation might clarify things: we provide all text from within our database, so the layout basically only contains fields, and when printing it could be that we print a Russian text, then a german text and then some hungarian. For these text we have to choose different character sets.
So the question is: is there a way to set the character set for a dycodoc template at runtime?

Patrick
bemsofpe
 
Posts: 35
Joined: Wed Dec 08, 2004 6:14 pm

Postby IDEAL Software Support » Mon Nov 17, 2008 3:55 pm

Yes, the Charset property can also be specified for a single dycodoc template TVpeObject. This means you can query a template for the contained objects - or use FindTplVpeObject() to search for an object by name - and retrieve the object itself. After having retrieved it, you can set for the object the Charset property (as well as many other properties). See the chapter "Templates" in the Reference Manual as well as the chapter "dycodoc Template Processing" in the Programmer's Manual for details.
IDEAL Software Support
 
Posts: 1633
Joined: Thu Nov 18, 2004 4:03 pm


Return to VPE Open Forum

Who is online

Users browsing this forum: No registered users and 14 guests

cron