Click here to Skip to main content
15,887,135 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hello, i have an issue:
i have Microsoft SMTP Virtual Server, which listens to smtp requests.
Each requests, needs to be passed to a directory, instead of passing it to a mail server.

i've used the "Smart host" and declared a dummy domain, thus, the files are staying at the "Queue" folder.

i wanted to make a job that listens to the directory, and parses those EMLS, then, i want to delete the files, but that was a problem, because the files are being used by another process (the SMTP server itself).

i found out that once in a while, the files are unlocked, then locked again, so i can sit on the directory and try to get the files out of there, but again, its not elegant.

* Is there a way to tell the SMTP virtual server to send the files to a directory?
* i've played a bit with the retry intervals, declared them to 99 minutes, but still, the server sometimes locks the files in the queue, so i can't take it out of there...

any help would be appreciated.

thanks!
Posted

1 solution

Think again. False approach.
It can't work out if you try to rip a file of another process.

Just to get it straight:
You need a handle on the emails waiting to be send in the queue?

There must be hook to tell the SMTP to drop the message instead of sending it.
 
Share this answer
 
Comments
arielbeck 3-Jul-12 3:03am    
I know its a false approach
i just want the SMTP server to put the files to a directory of my liking, then i want to parse it manually.

i couldn't find any hook or anything to the SMTP server, so i'm looking for a cleaner approach
TorstenH. 3-Jul-12 12:20pm    
I'm not firm with the Microsoft SMTP Virtual Server, but I would guess there is a path variable in the registry or something like that.

Otherwise - how about using another SMTP-Server? is that an option?
arielbeck 4-Jul-12 1:01am    
yes, though i wanted to use microsoft's one, but its not surprising that they don't fit.

i already made a POC with the hMailServer, and it seems to fit me.

thanks!

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900