C#, VPE and Slovenian

Knowledge exchange related to the VPE Report Engine and PDF Library

Moderator: IDEAL Software Support

C#, VPE and Slovenian

Postby mike » Fri Mar 10, 2006 9:13 am

Hi,

at the moment we test the virtual print engine and we are very enthusiastic :)

Now we have the problem with the slovenian character set. We use the VPE from a C# .NET 2003 environment. So VPE don't support unicode we have checkt the charset's offered from the VPE-Classes, but there isn't a charset runs with the slovenian special characters.

Any ideas?

Thx

mike
mike
 
Posts: 1
Joined: Fri Mar 10, 2006 9:01 am

Postby IDEAL Software Support » Fri Mar 10, 2006 4:29 pm

There is no slovenian charset available in the Windows operating system. But if you run VPE on a slovenian Windows version and leave the CharSet property in default mode, VPE should display and print the slovenian characters.

Regards
Thorsten Radde
IDEAL Software GmbH
IDEAL Software Support
 
Posts: 1633
Joined: Thu Nov 18, 2004 4:03 pm

Postby martin » Fri Mar 10, 2006 5:13 pm

Wait this cannot be the final solution...

There is CharSet.EasternEuropean

Shouldn't do this just fine?

I think the problem comes from a different point.

The .NET object is just a wrapper for the DLL. In my opinion the problem comes from conversion of UNICODE to ANSI which is done when the .NET UNICODE string is marshalled by .NET when calling the VPE DLL function. I might be wrong however.

In my opinion this conversion is using the system locale which is the source of the problem. If the system locale is not using the appropriate codepage matching the CharSet.EasternEuropean then already there the special characters are lost. In my opinion the wrapper should probably do its own marshalling using the appropriate codepage or the VPE DLL needs to provide a DLL export which accepts a UNICODE string and then is internally converting to ANSI using the appropriate codepage mathcing the VPE.CharSet. What sense would the VPE.CharSet setting have otherwise?

Regards,
Martin
martin
 
Posts: 8
Joined: Fri Mar 10, 2006 5:05 pm

Postby IDEAL Software Support » Fri Mar 10, 2006 6:50 pm

Indeed, this is a problem. The CharSet property of VPE was implemented a long time before .NET was known and when implementing the .NET component we didn't think about that issue.

In fact your code must be running on a Eastern European Windows in order to use by default the EastEurope charset. In v3.60 there is currently no option to change the codepage manually to EastEurope on a non Eastern European Windows.

Do you have some sample code available which demonstrates the manual conversion of a .NET string into an ANSI string with a given codepage, and how this can be marshalled to a DLL? We searched the internet but couldn't find any useful information. If you can provide some sample code, we could quickly implement this into the .NET component.
IDEAL Software Support
 
Posts: 1633
Joined: Thu Nov 18, 2004 4:03 pm

Postby martin » Sun Mar 12, 2006 10:37 am

I sent a mail to support@idealsoftware.com about this.
martin
 
Posts: 8
Joined: Fri Mar 10, 2006 5:05 pm

Slovenian

Postby nc1264 » Mon Apr 10, 2006 9:14 am

Have you considered to enter your text as RTF?
VPE has no problems in printing this. Even when printing multiple RTF strings in one box there is no problem. We do this and support Slovenian, Czech, Rumanian, etc.
nc1264
 
Posts: 28
Joined: Mon Dec 13, 2004 8:18 am

Postby IDEAL Software Support » Sun Apr 16, 2006 2:33 pm

Using RTF would be one solution. But we are currently fixing the problem with the CharSet property, so that plain text objects will also display text in other codepages correctly under the .NET environment. This is solely a problem with .NET. The fix will be made available in VPE v3.60 R5 in short.
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 44 guests