WatchDirectory home page
WatchDirectory Startseite (Deutsche Version)
Site WatchDirectory (Français)
  Welcome, Guest. Please Login or Register
YaBB - Yet another Bulletin Board
   
  HomeHelpSearchLoginRegister  
 
Page Index Toggle Pages: 1
FTP Upload Plugin Question (Read 2336 times)
JimmyDundee
YaBB Newbies
*
Offline



Posts: 1
FTP Upload Plugin Question
Jul 8th, 2006 at 1:06pm
 
I have a scenario where I have a legacy app that changes a filename once it has performed a task, and I'd like to upload the file via FTP to another server when the name change takes place. I thought I'd be able to do this with WatchDirectory but the rename option is greyed out on the plugin config screen.

Is this by design, or does this feature become enabled in the Pro version or the registered version? I only have the demo download running at the moment.

Apart from this small issue, the program is very nice!
Back to top
 
 
IP Logged
 
Gert
YaBB Administrator
*****
Offline



Posts: 2225
The Netherlands
Re: FTP Upload Plugin Question
Reply #1 - Jul 10th, 2006 at 2:08pm
 
Hello Jim,

This is not an evaluation limitation. The FTP plugin doesn't support renamed files (yet). A work-around that should work okay:

Use the "run an existing .bat file" plugin (see http://www.watchdirectory.net/wdhelp/plugins/wdopAutoRunBat.html ) to monitor for the rename event (you need to use the "Fast monitoring method" to be able to select the rename event). This .bat file should move the renamed file to another directory that is monitored by your ftp plugin (so it will see a new file). Use something like the following .bat file:

Code:
rem only interested in renamed files
IF "%WD_REASON%" NEQ "FILEREN" GOTO :EOF

rem move the renamed file to the directory that is watched by the FTP task
MOVE "%WD_FILE%" "C:\FilesToFtp"
 



So, your FTP task should monitor C:\FilesToFtp


Gert
Back to top
 

Gert Rijs - gert (at) gdpsoftware (dot) com
Blog: http://blog-en.gdpsoftware.com/
End Alzheimer's: http://www.alz.org&&...
WWW WWW GdPSoftware  
IP Logged
 
Page Index Toggle Pages: 1