IIS FTP Server Event Triggers

Hello,
We use our FTP Server to communicate with the outside world. Our Application puts the files in specific directories and the customers come and pickup the data. Is there a way to catch that event and have some custom code to delete the file as soon as the file is picked-up by the customer.


Thanks
Sridhar
smovvaAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

tncbbthositgCommented:
Not via ftp.  You could tell the customers to delete it but I wouldnt suggest it.  You can, however, create a subroutine that checks the creation date, compares with the new date, then deletes old files.  You could also check the last access date.  If the file was last accessed on it's creation date, nobody has retrieved it.  Otherwise, the dates would be different.

Hope this helps,
Pat
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
webwomanCommented:
You could also do it differently -- if they come in through an ASP page and grab the file, you could set it so that it deleted the file after it was grabbed.

Or you could have them log in, get a file list, grab the file, click on a checkbox to indicate it can be deleted, and delete it that way.

Or you could have them grab the file, change the file attribute to hidden, fire off an email to let them know the file will be deleted unless they respond differently, and then delete it next time they log on.

There are lots of ways, but you don't want to delete the file until you're SURE they've grabbed it. Transfers mess up, files get corrupted, etc. I certainly would be highly upset if I tried to grab the file, it got corrupted in transfer, and I couldn't go back and get it again.
0
smovvaAuthor Commented:
I need to know if the transmission of the data is successful and then delete the file. Is there a way to capture the Event when the file was succesfully transmitted and then the FTP server notifies my code?

Please let me know.
Thanks alot
smovva
0
Introducing Cloud Class® training courses

Tech changes fast. You can learn faster. That’s why we’re bringing professional training courses to Experts Exchange. With a subscription, you can access all the Cloud Class® courses to expand your education, prep for certifications, and get top-notch instructions.

tncbbthositgCommented:
You could ask them.  After they download the file, have them press a button confirming that it has arrived.

Pat
0
webwomanCommented:
There's no way you can tell if the file actually downloaded correctly. It could download, and be corrupted, it could start and they could be disconnected, or they could delete it by mistake before they used it.

You really do need to ask them BEFORE you delete the file. Actually, I wouldn't really delete it, even if they DID verify they'd received it. I'd just move it or set it to hidden, so you could not show it in the links.

People make mistakes, and if it's gone and can't be reconstructed and they really need it, it's going to be YOUR fault. Better to err on the side of caution, and be able to play the savior when they need a miracle. ;-)
0
tncbbthositgCommented:
Thanks for agreeing webwoman.  I was beginning to think that you just disagreed with anything I said :)

Pat
0
webwomanCommented:
Nah...sometimes it's just not clear what the question is, and there's almost always more than one  way (or 10!) to do something.

But here, there's really only one way. ;-)
0
COBOLdinosaurCommented:
This question has been classified abandoned. I will make a recommendation to the
moderators on its resolution in a week or two. I appreciate any comments
that would help me to make a recommendation.

<note>
Unless it is clear to me that the question has been answered I will recommend delete.  It is possible that a Grade less than A will be given if no expert makes a case for an A grade. It is assumed that any participant not responding to this request is no longer interested in its final disposition.
</note>

If the user does not know how to close the question, the options are here:
http://www.experts-exchange.com/help/closing.jsp


Cd&

0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Web Development

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.