+1  A: 

You should describe more about what you want to do, but typically if you have something that needs to run in the background and does not require direct user interaction, then a service often makes sense.

You can use Remoting to connect a front-end to your service as needed if you'd like.

Brad
Very true, though WCF is a better option than Remoting, which has been deprecated at this point.
Reed Copsey
Oh great... really!? Wow, I invested a lot of time recently figuring out Remoting and all of its crap. :-D Oh well... I guess I shall go learn WCF now.
Brad
@Brad, WCF is pretty awesome and decently easy to pick up. You can change functionality pretty easily with configs too
jlafay
+1  A: 

Yes, use a service for this kind of operation, but don't use filesystem watcher. If you poll for files in your service, dont use the Timer class either.

Do check to make sure the file is completed writing and is no longer locked before trying to move it.

Its trivial to poll for file changes (syntax may be off), and eliminates much of the extra programming associated with file system watcher events.

While True 'or your exit condition'
 Dim _files() as FileInfo = Directory.GetFiles(yourTargetDirectory)
 For Each _file as FileInfo In _files
  If _file.LastModifiedDate < DateTime.Now.AddMinutes(1) Then
    'move your files'
  End If
 Next

End While
StingyJack
what you recommend as an alternative to the filesystemwatcher.
czuroski
The only non-polling alternative is `ReadDirectoryChangesW` - a lot harder to get this right, and the same reliability problems.
Steve Townsend
I had good luck so far with this FileSystemWatcher wrapper...hides several warts. http://www.codeproject.com/KB/cs/EnhancedFileSysWatcher.aspx
kenny
A: 

Using a Windows service to wrap FileSystemWatcher is perfectly fine for what you need.

FSW is the right tool for the job (native code for filesystem watching is a bear to get right), and a service is the right mechanism to deploy it given you need 'always on' operation.

The service credentials will be independent of logged-in user too, which may be useful to you.

Steve Townsend
Couldn't disagree more about FSW. It has shown to be unreliable in several situations. Ripping it out and replacing with a polling mechanisim (managed not Win32) solved all problems.
StingyJack