How can I : "oh look there's a new email - do something"

R

Rob Meade

Hi all...this might not be a 100% asp question - but the app I'm writing
around it will be :eek:)

I guess I need a component or something that will happily run in the
background scanning the incoming mail directory - upon a new email arriving
I want something to happen.

This is for a small 'helpdesk' app - I am happy to have a pop at writing the
component myself, but wasn't sure the best way...presumably I would need to
be scanning the C:\Inetpub\mailroot\Mailbox\<--mail box name--> directory on
the server for a new file - I could achieve this I suppose by using a
database to record whats currently there, then every 5 minutes or so scan it
again and compare to the database...

Anyone done anything similiar in the past? I think I would like to write the
component myself to just get it to do exactly what I need - does the
'theory' above sound ok or are there other ways...

Ideally I want to be able to determine if a ticket number is in the email
header and then write a new row to a database and send an email or
something...

Any info appreciated,

Regards

Rob
 
A

Aaron Bertrand [MVP]

Why do you think this should be a component? Sounds like it should be an
application scheduled with Windows scheduler...
 
R

Rob Meade

...
Why do you think this should be a component? Sounds like it should be an
application scheduled with Windows scheduler...

Hi Aaron,

Just assumed to be honest, because there appearing to be so very many 'mail'
components around I guessed that this is what I'd need...

As it happens I have written a windows service in .net which is about half
way to doing what I want..its checking the mailbox, currently writing to the
event log, and I'm now trying to get it to dump some data to SQL server -
this is where I'm getting an error at the moment...

Has been an interesting ride - but its taken a while!

Regards

Rob
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,780
Messages
2,569,611
Members
45,285
Latest member
CryptoTaxxSoftware

Latest Threads

Top