Cabarc exe not unzipping when filepath has unicode characters [closed] - c#

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
This question does not appear to be about programming within the scope defined in the help center.
Closed 9 years ago.
Improve this question
I am trying to unzip a file from a source folder whose name is in Unicode(Chinese) using Cabarc.exe utility.
But the utility is not unzipping the same.
If i rename the folder to English, then it works.
Is this a known issue? Any work arounds?
Code: Cabarc.exe -p X "C:\测试\sourcefile.zip" "C:\ProgramData\destination"\

Sounds like a typical non-Unicode ('ANSI') compiled app - in which case there's not really much fix possible, any character used in the command line that is not available in your locale code page will necessarily fail.
Setting your Windows locale to code page 936 ("language for non-Unicode applications" -> Chinese) would allow you to use Chinese characters, but not any other non-Chinese characters that aren't available in that code page.
The command chcp 65001 to set your code page to UTF-8 for a particular session would in theory allow you to use all Unicode characters. Unfortunately there are a number of bugs in the implementation of code page 65001 that cause widespread breakage... I don't know if cabarc would survive it.

Related

VS Code and C# - Double quote followed by an underscore [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
This question does not appear to be about programming within the scope defined in the help center.
Closed 1 year ago.
Improve this question
I've been having this problem in VS Code and C# where if I had a double quote followed by an underscore, like the string "_something", the syntax highlighting below that line gets ruined.
Here is an example:
When the offending line is commented out, the syntax highlighting works as expected. But when uncommented, the syntax highlighting gets ruined. In this case, the string starts with two underscores, but this also happens with only one underscore. How do I go about fixing this setting in VS Code?
The plugin I'm using for the theme is the Material Theme with default settings, although it doesn't seem to matter which theme is used. Thanks!
It seems that there was a different plugin causing the problem, linked below:
Identical Sublime Monokai C# theme and colorizer
The syntax highlighting still exhibits the problem mentioned above even when only this plugin was enabled, therefore the problem is caused solely by the plugin and not due to conflicting plugins. I'll now be reporting this issue on the plugin's repo.

file path shortener c# [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
This question does not appear to be about programming within the scope defined in the help center.
Closed 7 years ago.
Improve this question
So I am using the StreamReader class, and in the spot where my address goes I have #"S:\Temporary Shared Space\Project\Boyscout3\Data\full_pack.txt" My colleague believes that instead of typing out that super long filename there is a short way of getting it done. My colleague believes that you can just put in #"full_pack.txt*" and it will look for all file names in your computer that has that name. Is my colleague crazy or is this an actual thing?
My colleague believes that instead of typing out that super long filename there is a short way of getting it done.
It depends on what context you are executing the program in. You can use a relative path to make the string shorter (and more flexible).
My colleague believes that you can just put in #"full_pack.txt*" and it will look for all file names in your computer that has that name.
I don't know why you added a * but unless you are using a search method you will need to remove that character. "full_pack.txt" that will grab full_pack.txt from the current directory, wherever that is.

Decrypt files in a VB6 installer. like file.ex_ [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
Questions asking for code must demonstrate a minimal understanding of the problem being solved. Include attempted solutions, why they didn't work, and the expected results. See also: Stack Overflow question checklist
Closed 9 years ago.
Improve this question
I need to decrypt the files that are on a VB6 install package. Once files are in the installer are like file.bm_ and when I decrypted this file, this file is named file.bmp. I try with the program win.rar and saw recognized as encrypted files and decrypted well, but I don't know how to do this from an application in c#.
Thank you.
Ok, had to find these.
If GZip doesnt work and you need a last resort. There are some DOS files bzip.exe, bunzip.exe and a win32 version that you can still likely find somewhere on the net. Mine are dated 2007 but they still work as far as I know (last I think I needed them was on XP 64, 2011). The upside is that they handle several compression formats.
Like I said, a last resort.

How should keyboard mnemonics be localized? [closed]

Closed. This question is off-topic. It is not currently accepting answers.
Want to improve this question? Update the question so it's on-topic for Stack Overflow.
Closed 9 years ago.
Improve this question
Is there a standard approach to localizing (internationalize) keyboard mnemonics? For example, in Windows Explorer (English), if the user types Alt-F then C, the File menu opens and then the Close operation is selected.
For a language using qwerty, I guess you can change the mnemonic letters depending on the translated words. But what about a language like Chinese? I've seen some programs put the mnemonic after label in parenthesis, but it doesn't seem ideal.
Reposted: https://ux.stackexchange.com/questions/39074/how-should-keyboard-mnemonics-be-localized
With Java, you can use ResouceBundles. With them, you can create files that hold, each one, strings and objects for a certain locale. For example, you write Resource Bundles for en, en_US, en_UK.
Let's say en_US is the default for English. You write en as if it where en_US, leave en_US blank and just write differences between en_US and en_UK in the en_UK file, Java will find the "equals" in the default en file.
This presentation will introduce some of the concepts of Java i18n.

USB Memory Stick hidden partition [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question may be able to be answered.
Closed 8 years ago.
Improve this question
I am writing a kind of accounting software which will run portable on a USB Memory Stick. I would like to make a hidden partition on the Stick to store some data to check the validity of the database file on the main partition. Currently I don't know how to start. Could anyone tell me any way to do it? What partition type should I use? How do I read from it with C# .NET? What Win32 APIs are there. Anything.
UPDATE:
Here's a scenario, I use a file (encrypted) to store a value (e.g. Amount of money), the user can backup that file, and whenever he restore the file, he restore the value at the time he backup. That's why I want to have a hidden partition. Encryption is not an option for me.
Rather than hiding you can use encryption
How to lock a folder on a USB drive?
There is a TrueCrypt project that does something similar you want. It is open source, so you might take a look how they are doing that.

Categories

Resources