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: Remote Server Path Separator Character

You have posted it two days ago only!?!

And again, you can always use forward slash.
aksarben

Re: Remote Server Path Separator Character

To be honest, it’s been so long I forgot I had submitted this.

My Web hosting company recently moved my site from an old Microsoft IIS server to a Linux server. So the upload script I had been using broke because it assumed the path separator character was always a backslash (used on Windows). I was trying to figure out a simple way to determine when we should convert paths of the Windows files to upload so they used the separator character expected by the server.

I finally took the easy way out and just always assumed the separator character should be a forward slash, and added a line to the PowerShell script that always replaces back slashes with forward slashes. If I ever get moved back to a Windows server, I'll store the server’s expected separator character in the registry & read it when needed. If I live that long…

Sorry for the trouble. If I had remembered this post I would have closed it a long time ago.
martin

Re: Remote Server Path Separator Character

Can you be more specific about the problem you are trying to solve?
WinSCP scripting always uses the forward slash – / – for the remote paths.
aksarben

Remote Server Path Separator Character

Is there an easy way for a script to determine the path separator character used by the remote server (e.g., / vs. \)?