Community forum

Please note that VisualCron support is not actively monitoring this community forum. Please use our contact page for contacting the VisualCron support directly.


paulnus
2011-05-24T17:24:01Z
😢 Was hoping to use the VisualCron rename file task to convert some files I need to FTP to lower case and running into some troubles.

I tried doing this for the string mask..

Quote:

{STRING(ToLower|*)}



However, it looks like the lower case gets does not get applied to the contents.

Quote:

\\filer3\General\IT\Puzzle_Answers_Test\ANWS0529.gif > \\filer3\General\IT\Puzzle_Answers_Test\ANWS0529.gif



I need the file name to end up being "anws0529.gif"

Is there a way to get around this in VC? I can certainly script something but wanted to stay native to the application.
Sponsor
Forum information
ErikC
2011-05-26T08:09:14Z
Hi paulnus,

Welcome to the forum!

This could be done by using a file trigger on a folder and using one file rename task.
Use the variable filename in the file mask:
{TRIGGER(Active,LastTrigger,File.Result.Name)} 

and rename the file to a different folder using the ToLower function:
NewFolder\{STRING(ToLower|{TRIGGER(Active,LastTrigger,File.Result.Name)})}

Now the filename is in lowercase. You can't put it in the same folder because Windows doesn't care abaout lower and upper case. Putting it in a different folder is the solution here.

Regards,
Erik
Uses Visualcron since 2006.
paulnus
2011-05-26T16:34:55Z
Thank you, that does drive the behavior Im looking for.

With that said, I'm not getting the exact results on the file trigger as I had hoped.

Let's say I copied 14 files into the folder with the Trigger. It seems to only rename a few of the files. Meaning, it may only move 4 files and then I will have 10 files left in the directory that it did not move.

Once I move the rest of the files out and back into the folder, it moves a few more. I have to keep moving files in and out of the folder in order for it to finally move all of them.

Are you familiar with this type of behavior from a file trigger?
Support
2011-05-26T16:36:44Z
Make sure you set "Put Job in queue" in the main settings of the Job.
Henrik
Support
http://www.visualcron.com 
Please like  VisualCron on facebook!
paulnus
2011-05-26T16:51:23Z
Ah. Doy!

Thank you very much! I have much to learn but this is far better than dealing with all the different PERL, VBScript, Python, etc, etc, etc,... scripts that our previous developers did in different ways.

Scroll to Top