Report Design
 Crystal Reports Forum : Crystal Reports 9 through 2020 : Report Design
Message Icon Topic: convert symbols in data to unicode characters Post Reply Post New Topic
Author Message
tucker2m
Newbie
Newbie


Joined: 04 Aug 2011
Location: United States
Online Status: Offline
Posts: 15
Quote tucker2m Replybullet Topic: convert symbols in data to unicode characters
    Posted: 18 Jun 2012 at 9:39am

Greetings everyone,

Our database does not currently support unicode.  We have been testing it out and keep finding issues with it, so until the issues can be resolved, we have opted out of enabling this function. 
In the mean time, we are using the following character " ^ " before the letters "o" and "u" to indicate there should be a line above the letter (unicode equivalent of ō and ū).  The problem is then in our reporting functions.  I am having issues with the correct formula to use to convert ^o to ō and ^u to ū in the final report. 
 
For the fields where the letter with the symbol appear, I am already using a formula to select the data, so I have to figure out where I can add a new formula to convert the symbol into the unicode character.  I have tried to add a formula on the font field under the format field section, but the different formulas I have tried do not work.  I keep getting prompts that the rest of the formula is missing or that the formula must be a string.  I have also selected an Arial Unicode MS font with the hopes that once I can figure out how to convert the characters to unicode that the font will not cause any issues.
 
Does anyone else use unicode characters in reports and in their data?  Any suggestions on where to try to add formulas to replace text with unicode characters? 
 
Any help is much appreciated.  Thanks.
IP IP Logged
lockwelle
Moderator
Moderator


Joined: 21 Dec 2007
Online Status: Offline
Posts: 4372
Quote lockwelle Replybullet Posted: 19 Jun 2012 at 2:50am
i would think that you would a Replace function, so if you have this code 'everywhere' you might want to think of a common function for the report, then you would have a 'simpler' set of formulas...but you would still need a formula for each field in the data that you have the code.
 
never used unicode, but I would think that the general format of the formula would be:
replace("^o", unicode)
 
HTH
IP IP Logged
tucker2m
Newbie
Newbie


Joined: 04 Aug 2011
Location: United States
Online Status: Offline
Posts: 15
Quote tucker2m Replybullet Posted: 19 Jun 2012 at 5:37am

I have tried the replace function, but crystal sees the symbol "^" used before the letter as code and then indicates that I am missing a parenthesis at the end of the formula.   Here is the formula I used in the font field:

replace ("^o"); ChrW (014D)
 
Crystal reports there is an error with this and that it is missing the parenthesis after the D.   Thanks for the input.
 
IP IP Logged
lockwelle
Moderator
Moderator


Joined: 21 Dec 2007
Online Status: Offline
Posts: 4372
Quote lockwelle Replybullet Posted: 19 Jun 2012 at 6:23am
should be:
replace ("^o",ChrW (014D))
 
I am not sure how Crystal will interpret 014d...if it is a hex number, convert it to integer (333)
IP IP Logged
tucker2m
Newbie
Newbie


Joined: 04 Aug 2011
Location: United States
Online Status: Offline
Posts: 15
Quote tucker2m Replybullet Posted: 13 Aug 2012 at 7:52am
Hm, I can't seem to get it to work regardless of how I change the code.  Perhaps Crystal Reports XI doesn't support it. 
IP IP Logged
Post Reply Post New Topic
Printable version Printable version

Forum Jump
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



This page was generated in 0.031 seconds.