Deny ftp files with dashes

I routinely upload files to a server but they cannot contain dashes. Several people do this for me throughout the day and it's nearly impossible for them to not have dashes when they upload because another local server we upload requires the dashes (probably running different OS). Anyway, please please tell me there's a way for opus to deny or at least remind the user to remove dashes before they upload. We already have a cool macro in opus to remove the dashes from filenames, I just need a way to stop the process and alert the user they need to do this before anything is uploaded to this server.

Any ideas I hope? :slight_smile:


Well it were me I'd use a button with commands something like the one at the end of this message. It does the following in this order:

  1. Go to the offline folder containing the files to upload.

  2. Select anything that has a - in the file name.

  3. Opens a dialog box that does nothing other than to give you a message about any selected files/folders.

  4. If OK was pressed in above dialog box, Opus continues and loads the saved layout which logs into the FTP site.

Bear in mind in my button example below, the folder and saved layout are called WITR which is an actual client of mine. You would have to change the first and last button command lines to what you need. The commands follow this line.

sync:dopusrt /cmd Go "C:\Mine\Upload\witr"

sync:dopusrt /cmd Select PATTERN=-

sync:dopusrt /cmd clipboard {dlgstring|Any FILES or FOLDERS that are selected have dashes in the name|Press CANCEL and rename them or OK to log into FTP site.}


Hello ,

I can answer only for Linux Servers ( servers with PHP support ).
It's insane to me that a Linux server would balk at a dash character !

It's always a good idea not to include space characters in Linux filenames.
I doubt very much that is the problem, but if you do have any space characters in these files, see if eliminating them solves the problem.
I very much doubt it will, but that's the only suggestion I can possibly think of here.

Ooops, well actually my suggestion is get a new web host with a Linux Server!

:opussanta: porcupine

Well when I upload to a "server", it's actually an online distribution service I send TV spots I make. I have no say whatsoever in the dashes thing, unforunately. I was just trying to figure out a way for Opus to help me get around this issue as it happens all the time. :frowning: Save us from ourselves, Opus! :slight_smile:

Do they always upload from the same folder(s)? If so you could set up a folder format for those locations which filters out all files with dashes in them.

Once people realise why they can't see the file they're selecting they could press a button which clears the filter, then another button which auto-renames all the files to remove the dashes. (Or a button which does both.)

That's a great idea, Nudel! We have a master folder on our Z drive that holds our files. Can I assign just that folder a rule to color files with dashes in them? Like highlight them red? That would be fantastic! If we can't color them then hiding them might be the next best thing.

I'm kind of stumbling around but I think I found out how to hide the files with dashes. I went into folder options and did a hide filter with string - and saved just for that folder. It does indeed hide them. I can't figure out a convenient way to unhide all files without going into menus.

I'm afraid if I hide files on them though it just might provoke a lot of questions and waste my time. A way to show colored files with dashes would be outstanding! Any way you think?

To unhide everything you can make a toolbar button which runs this command:Set SHOWFILTERFILENAME="" Set SHOWFILTERFOLDERS="" Set HIDEFILTERFILENAME="" Set HIDEFILTERFOLDERS=""

I don't think you can colour files based on a pattern at the moment, sorry.

Is there a way to check for a pattern and then alter that file's filename? Like have it search for -.mpg to search for all mpg files with dashes, then run a command to append a bunch of dashes ------- onto the end of the file name? We already have an opus macro to take out the dashes so I figure if we call attention to the filename by use of dashes, all the user will have to do is select all of the files in question and hit the dash remover macro and it will be done!

What do you think?

Just do a rename from -.mpg to ------.mpg

How many files are in the folder you guys upload from and does your normal work flow habit go like; copy files to master folder on Z drive, then immediately upload files to ftp server? If there are not tons of files, and the files usually sit in the master folder for a period of time before ftp upload, have you thought about running the 'remove dash' rename macro on a scheduled basis - like every 15 minutes or something?

Otherwise, I think JohnZ might have had the best all-around suggestion - to change the basic way you perform your uploads to a button or something that will include all of the steps that take everything into consideration... rather than to remember to manually hit the rename macro before uploading etc etc.