We help IT Professionals succeed at work.

copy new file vb.net

StewSupport
StewSupport asked
on
let's say i have 10 files name 1.jpg through 10.jpg. i can copy these files over using copyfile function. what i want to do is if someone add new images in that folder, 11.jpg, 12.jpg for example, how do i detect that this folder content is change and now i need to copy only the new files over? please help. thanks. right now i'm using my.computer.filesystem.copyfile() to copy. is there better way to this? thanks
Comment
Watch Question

HainKurtSr. System Analyst

Commented:
what about an app like this

WatchDirectory
Monitor Directories for Changes

http://www.watchdirectory.net/
HainKurtSr. System Analyst

Commented:
I used that one in my solutions and it is really nice :) for example you can do this

if a new image file is copied to somewhere, get it, resize it, copy to different locations, archieve somewhere, ftp to some site etc etc...

once you setup and write scripts for events, it does the rest...

Author

Commented:
great but i need some code sample.
Senior .Net Consultant
Top Expert 2016
Commented:
Most Valuable Expert 2012
Top Expert 2014

Commented:
Do you need to check for changes in folder while your app is running or changes from last time when your app is started?