c# AND METHOD FOR SPECIFYING ARGUMENT INCLUDING JAPANESE IN EXECUTION OF OTHER APPLICATION AT COMMAND PROMOTE

Asked 2 years ago, Updated 2 years ago, 96 views

As the title says,
○How to specify a string containing Japanese to process.start arguments in C#
and
○How to specify a string containing Japanese in the application execution argument at the command prompt
I don't know.
Currently, the running application receives a garbled string.
I want to run TeighaFileConverter.
https://www.opendesign.com/guestfiles/teigha_file_converter
This application takes input directories, output directories, file names, etc. as arguments, so I want to specify a string containing Japanese (although it should only consist of alphanumeric characters in the first place).
I would appreciate it if you could let me know if there is any good way.
Thank you for your cooperation.

c# windows command-prompt

2022-09-30 20:22

1 Answers

I don't have any.Windows will convert and retain the entered string to Unicode.Then, if the application reads in Unicode, it translates from Unicode to ANSI, and then returns each.
C# works with Unicode, so Unicode is passed correctly around here.

I guess the application read the command line arguments in ANSI, but then the characters were garbled due to improper handling.

Even if the caller can pass some different value, this time the application will fail to open the file.
In the end, you have no choice but to fix the application in question (although of course you can configure it correctly if you have any configuration).


2022-09-30 20:22

If you have any answers or tips


© 2024 OneMinuteCode. All rights reserved.