08-08-2022 06:51 AM
hello.
I want to display the symbols "Σ" and "φ" in Japanese, Korean, and English environments.
However, when displayed on a character display, it is displayed in a Japanese environment, but the characters are garbled in other environments.
Next, I tried the method of inputting a string in hexadecimal, inputting it in unicode, converting it to ascii, and displaying it in the string display.
As a result, it was displayed correctly in the Japanese and Korean environments, but not in the English environment.
Is there a way to display it in the English environment as well?
The program that converts from unicode to ascii is based on the following page.
https://forums.ni.com/t5/Reference-Design-Content/LabVIEW-Unicode-Programming-Tools/ta-p/3493021
I've tried adding "UseUnicode=True" to Labview.ini and Force Unicode Text as seen on this page, but no change.
The environment is labview2017.
Many thanks for reading,
kanazawa
Solved! Go to Solution.
08-08-2022 08:18 AM
You might need to play with the system language settings:
control panel => region => Administrative => Language for non-Unicode
08-08-2022 09:13 AM
Converting the Sigma to ASCII results in "S". So everything is ok with your program...
You need to enable Unicode for labview and for the indicator. Then you can write the 2 unicode bytes 0xA303 to the indicator.
Whats the reason for the additional 2 bytes (0x0000)?
08-08-2022 06:47 PM
Thank you for your reply.
For the "Language for non-Unicode" setting, select "Japanese", "Korean", or "English" according to each environment.
In addition, the following locations are matched with the settings above.
Region and language => format, location
Is there any other place to set it?
Best regards
kanazawa
08-08-2022 06:53 PM
Thank you for your reply.
I didn't know that sigma converts to ASCII and becomes "S". Thank you.
Is it OK to enable Unicode in the indicator with the "Force Unicode Text" setting?
I will try.
I want to display "Σ" as "Σn" or "Σq", but it was garbled without the additional 2 bytes (0x0000).
Best regards
kanazawa
08-09-2022 04:09 PM
@kan-sad wrote:
Is it OK to enable Unicode in the indicator with the "Force Unicode Text" setting?
Yes
Attention: Unicode (more exactly: it is UTF-16LE) is possible but did not work in all situations. For example: there is an ugly issue with ring controls, so ring controls don't work for all unicode characters. There is also a problem if a control displays some ASCII characters ("Force Unicode Text" is false) and you switch to "Force Unicode Text" using property nodes. I don't remember, what sometimes happens in this case, but my own library didn't do that and the NI library also prevents this situations.
BTW: For Σn you have to use "A303 6E00" and for Σq it is "A303 7100".
Martin