-
Notifications
You must be signed in to change notification settings - Fork 21
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Need to enter data in Thai language in wc3270 emulator #51
Comments
Assuming that your host supports it, the command-line option '-codepage thai' will set up wc3270 to use code page 1160 when talking to the host. With that, wc3270 should be able to display Thai text from the host and accept Thai input from the keyboard. For scripts, however, wc3270 uses the system's ANSI code page. You can see what this is by entering 'show localencoding' at the wc3270> prompt. If it shows CP874, then your computer is configured for the Windows Thai code page, and you can use Thai characters (encoded in code page 874) in your scripts. If it shows something else, then scripts won't be able to use Thai characters. To work around this, you can use the '-utf8' command line option. This will switch wc3270 to use UTF-8 encoding for scripts, which allows (UTF8-encoded) Thai characters to be used. |
Hi, show localencoding is CP874 What is the syntax to pass utf8 to Open connection? coz when I tried -utf8 it worked, but when I am tryine -utf8 True or so, it fails to launch. |
The correct syntax for the '-utf8' option is here: https://x3270.miraheze.org/wiki/-utf8_command-line_option |
Hi, |
We must somehow be talking about different things. Are you using some sort of separate scripting tool to run your wc3270 session? '-utf8' is a command-line option, which is passed to wc3270 when you start it, just like '-xrm "wc3270.model: 2"' which I think you are already using. |
Yes Default value for this is false. |
The proper syntax is '-utf8'. It is a Boolean option and does not take a parameter. The fact that the application launched successfully when you just passed '-utf8' indicates that you had passed it correctly. However... now that I understand that you are using Robot Framework to automate wc3270, rather than wc3270's scripting facility, the '-utf8' option is not going to help you here. '-utf8' only changes the behavior of wc3270 scripts. It does not change wc3270's interactive behavior, and as far as wc3270 is concerned, running under Robot Framework is still interactive use. As far as I know, entering Thai text should work with wc3270 and Robot Framework as long as the text is encoded as Windows code page 874 https://en.wikipedia.org/wiki/ISO/IEC_8859-11#Code_page_874_(Microsoft)_/_1162. Again, I have never used Robot Framework, so I don't know how hard getting this encoding right would be. May I ask what it is you are trying to do by automating wc3270 this way? Are you trying to gather some data from the host (commonly known as screen scraping), or are you trying to actually present the user with the wc3270 display? If you are doing screen scraping, there are definitely easier ways to accomplish this. |
Hi Team,
We need to enter values in Thai in wc3270 emulator.
Tried using charset and utf8, but same did not worked.
Please help to suggest how we can achieve this.
The text was updated successfully, but these errors were encountered: