Graphicvar UTF8 (1208) or UCS2 (13488)

Use this board to ask questions or have discussions with other Rich Displays users.
Post Reply
lsmichel
New User
Posts: 3
Joined: Wed Oct 14, 2015 9:42 am
First Name: Michel
Last Name: Sess
Company Name: oo2 formations et services
Phone: 48297663
Address 1: Nean
Address 2: Nean
City: Abidjan
Country: Ivory Coast
Contact:

Graphicvar UTF8 (1208) or UCS2 (13488)

Post by lsmichel »

Hi , i want to create a table , with UTF8 (1208) or UCS2 (13488) columns.
I want to display data from the table with ProfoundUI.
So i have created a rich display file and stated all the fields referring to the table.
In my rpgle program i have stated a data structure like the screen format.
I use Eval-corr when a retrieve data from the table. But i get an error.
How to display unicode field with ProfoundUI ?
Thank to help me.
Scott Klement
Experienced User
Posts: 2711
Joined: Wed Aug 01, 2012 8:58 am
First Name: Scott
Last Name: Klement
Company Name: Profound Logic
City: Milwaukee
State / Province: Wisconsin

Re: Graphicvar UTF8 (1208) or UCS2 (13488)

Post by Scott Klement »

Instead of 13488, I would use 1200. CCSID(1200) is UTF-16 which is a superset of 13488 (UCS-2)

This is done in the binding dialog when binding a variable to a property. Under "Data Type" choose "graphic". Then click the "keywords" button at the bottom of the dialog
uni1.png
uni1.png (30.65 KiB) Viewed 656 times
In the keywords dialog, type CCSID(1200) and click "Add" followed by "Ok"
uni2.png
uni2.png (17.39 KiB) Viewed 656 times
This has now been defined as a Unicode (UTF-16) field. It will appear in your RPG program as data type C (UCS-2).

I would also consider adding a CTL-OPT or H-Spec to tell RPG to use CCSID 1200 for Unicode fields:

Code: Select all

H CCSID(*UCS2: 1200)
Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest