Last post Aug 20, 2008 01:50 PM by kirilminev
Aug 19, 2008 04:17 PM|kirilminev|LINK
I am developing utlity that needs to listen to ftp folder for received files. How can I set up a loop itteration that will execute the code
FindFiles() 'Has to be called constantly to look for new files.
Can someone help with a starter code.
Any help will be appreciated.
Aug 19, 2008 11:02 PM|bhadelia.imran|LINK
There is a class name FileSystemWatcher, which allows you to keep watch on any folder.
have a look at this link, its server which continusly watching and producing report
Hope this helps you.
Aug 20, 2008 02:54 AM|TATWORTH|LINK
For code to be running so as to be able to poll every 5 seconds, normally means writing a windows service.
What language are you writing in?
Where is your site to be hosted?
Aug 20, 2008 09:52 AM|kirilminev|LINK
I am using vb.net I tried the FileWathcher and Time object, but it doesn't work on console app only on windows forms.
Aug 20, 2008 10:39 AM|BlueJam|LINK
I'd go with the above suggestion of a windows service. You could use a
FileSystemWatcher event or you could use a Timer to scan the directory every 5 seconds.
Example Code :-
Aug 20, 2008 01:50 PM|kirilminev|LINK
Thanks that worked