Post a reply

Before posting, please read how to report bug or request support effectively.

Bug reports without an attached log file are usually useless.

Options
Add an Attachment

If you do not want to add an Attachment to your Post, please leave the Fields blank.

(maximum 10 MB; please compress large files; only common media, archive, text and programming file formats are allowed)

Options

Topic review

martin

Re: Replace UTF8 character

We will see, if more people ask for this.
MajorTom2004

Re: Replace UTF8 character

Thanks for the answer even if it is not what I hoped for.
Do you plan for the future to implement UTF-8 Multi-Byte or Unicode replacement?

Cheers Thomas
martin

Re: Replace UTF8 character

Unfortunately, it's not possible.
MajorTom2004

Replace UTF8 character

With Ascii characters, the replacement works fine for me. In the meantime, I found a usecase where I need to replace a 3 Byte long UTF8 character, for example 0xE28093 (is it called hyphen?).
I can find no way to build up the LocalInvalidChars string in order to make the replacement work.

Thanks, any help is appreciated.
Thomas
MajorTom2004

Re: Question to Transfer Settings Dialog / Replace '\;*...'

Hi Martin.
The solution with the INI file was not successful for me, not even changing to Registry and extending the string there. I have no clue what I am doing wrong, I checked it over and over again ...
However, the get /remotepath/* C:\localpath\ ... solution did work for me, as well as the
$transfer.AddRawSettings in a PowerShell script.

Thank you for your fast response, I appreciate!
Thomas
martin

Re: Question to Transfer Settings Dialog / Replace '\;*...'

If I set
LocalInvalidChars=/%5C:*%3F"<>|'

the ' in the downloaded files are replaced with %27, as expected.
. 2023-03-30 08:31:18.112 Transfer done: '/remotepath/quote"'' => 'C:\localpath\quote%22%27' [543]

Make sure your INI file is actually used by your script. Post session log file if you still cannot make it working.

Though better than setting it option in INI file is to set it in the script:
get /remotepath/* C:\localpath\ -rawtransfersettings "LocalInvalidChars=/\:*?\""<>|'"

See https://winscp.net/eng/docs/rawtransfersettings#localinvalidchars
MajorTom2004

Question to Transfer Settings Dialog / Replace '\;*...'

Hi all.
In the WinSCP.ini-file there is a section for every Transfer profile [Configuration\Interface\CopyParam\n], the sections contain (among others)
ReplaceInvalidChars=1
LocalInvalidChars=/%5C:*%3F"<>|

Is there any chance to extend the LocalInvalidChars list in order to replace any special characters, i.e. the single quote? I have tested with adding the single quote ' (without the double quote around it, of course) as well as %27, unfortunately without any effect.
We transfer files from an SFTP server, those files frequently contain (Windows allowed) special characters, however, the downloading system has problems to handle some of them.

I have tried several configurations, WinSCP 5.19.6 and 5.21.7, FTP server running on Linux (I guess, I don't have direct access to that machine), MacOS and Windows. The standard characters as defined in the list are replaced correctly, but not additionally inserted characters.
Thanks,
Thomas