WatchDirectory Forum
http://www.watchdirectory.net/cgi-bin/yabb25/YaBB.pl
watchDirectory forums >> Plugins >> Automatically Rename Files Not Understanding Move
http://www.watchdirectory.net/cgi-bin/yabb25/YaBB.pl?num=1214870241

Message started by streamdispatch on Jul 1st, 2008 at 1:57am

Title: Automatically Rename Files Not Understanding Move
Post by streamdispatch on Jul 1st, 2008 at 1:57am
I have a question on renaming files that I don't seem to come across in searching this forum although it seems very basic.

On the first part of the Automatically Rename Files plugin - I put in a few parameters for Old and New Values. It's the "Move to Filename [including directory] part that I'm trying to figure out. Let me explain what I need and see if I'm going about this right.

I don't need to Move any files period. Basically this program will be run on one computer and checking a network drive for pdf and doc file types to rename with the Old/New value parameters.  There will be many subfolders in this watched folder. The intention is for these files to NOT move anywhere - to follow the Old/New value parameters, rename the file and stay put.

That said - if you leave the Move to Filename blank - it won't let you go next. What details do I need to put into Move to Filename to keep all files renamed in the "same folder as entered" mode?

Thx!

Title: Re: Automatically Rename Files Not Understanding M
Post by streamdispatch on Jul 1st, 2008 at 2:04am
this may be in the wrong forum - probably should be in How To. My apologies - if Admin can move this.

Title: Re: Automatically Rename Files Not Understanding M
Post by Gert on Jul 1st, 2008 at 7:07am
This forum is fine.

I guess you need to enter something like
[code]C:\{monitoreddir}\{relativedir}\{filename}[/code]
as the "move to" destination.

You should make very sure that this "new file" is not detected by the same task again by appropriate use of filters.

Gert

Title: Re: Automatically Rename Files Not Understanding M
Post by streamdispatch on Jul 3rd, 2008 at 12:38am
Gert. Thanks for your speedy reply but for some reason I can't get my head around this.

The trial of this (if I can get this to work - I'll buy this in a heartbeat) is running on a computer we'll call Computer 1.

It is monitoring a network path in the Directory to Watch folder - the path is \\storemore\Storage\AVIRoot2\-_PREP_-\test. This path leads to Computer 2.

If I put in C:\{monitoreddir}\{relativedir}\{filename} and put a txt file that has a comma in it (which has been designated to be replaced with a "-", the file gets processed per the Filter Event but it goes somewhere where I have no idea. It shows up in the message in the Control Center, the View History shows nothing and I look for C:\MonitoredDir\ on the drive of Computer 1 and 2 and do not find this file.

Basically there are two examples of what I'm looking to do with this.

Say there's a PDF in this path: \\storemore\Storage\AVIRoot2\-_PREP_-\Mobar\LawVid08\Course Materials, John Williams&Joe.pdf

This would be renamed to: \\storemore\Storage\AVIRoot2\-_PREP_-\Mobar\LawVid08\Course_Materials-_John_Williams-Joe.pdf

The Old and New Values are no sweat - it's getting the Move to Filename down as I don't want to Move the file at all but simply monitor \\storemore\Storage\AVIRoot2\-_PREP_-\ and all of it's subfolders for new pdf and doc files that are set up in the Filter Events and when they hit any subfolder - it will automatically rename these files.

I also tried \\storemore\Storage\AVIRoot2\-_PREP_-\{monitoreddir}\{relativedir}\{filename}\{monitoreddir}\{relativedir}\{filename} in the Move to Filename field and the behaviour was the same as C:\{monitoreddir}\{relativedir}\{filename} when I put a file in - it shows up in Control Center Last Message as identified - disappears from the test folder and goes somewhere I have no idea - not on Computer 1 or Computer 2 on the C Drive in any created folder that is indicative of anything relating to the input.

Any help on this is greatly appreciated.

Thanks!
Reid




Title: Re: Automatically Rename Files Not Understanding M
Post by Gert on Jul 3rd, 2008 at 7:54am
Reid,

Hard to say from here....
Can you create a backup of this task:
* stop the task
* right-click it
* select the option "Backup selected task"

Please email me the ZIP this creates so I can have a look.

Gert

Title: Re: Automatically Rename Files Not Understanding M
Post by streamdispatch on Jul 3rd, 2008 at 6:35pm
I just figured it out! Thanks though Gert. Getting my credit card.

Reid

WatchDirectory Forum » Powered by YaBB 2.5.2!
YaBB Forum Software © 2000-2017. All Rights Reserved.