2

Firstly I know that there were a lot of similar topics. What is more the most of them are advising to use hMailServer. Ok, ok cool! But the main question is how to configure this or that sh*t to work with IIS 7.0 and lolcalhost? I don’t know what the hell should I put into domain name since I have only localhost?! How can I be sure that IIS relaying applications which could send mail via IIS 6.0 can send e-mail after introducing hMailServer and IIS 7.0? How to test that feature?

Can anybody tell me step by step procedure without assuming that I’m administrator and I know what to fill in there? PLEASE HELP!!

1 Answer 1

1

These docs are the step by step instructions for setting up email on IIS7. No you should not have to (or frankly should) install Hmailserver (why would you need to when you can send mail directly from any windows system even without a relay installed?).

A little detail missing is to ensure that you go into properties of the SMTP server, Click on Access tab and Relay, add an entry for 127.0.0.1

To test

you can either manually send an email from the machine (telnet to port 25 from the machine etc...) or use a script like this one (powershell)

$emailFrom = "[email protected]"
$emailTo = "[email protected]"
$subject = "your subject"
$body = "your body"
$smtpServer = "Localhost"
$smtp = new-object Net.Mail.SmtpClient($smtpServer)

$smtp.Send($emailFrom, $emailTo, $subject, $body)
4
  • Sorry but I didn't catch it. Firstly I was trying what you advised earlier. I failed. Secondly why are you saying that I don’t need any smtp server installed locally while everyone tells to do this? Please be more precise and give me step by step procedure which works for you. Jul 6, 2010 at 21:36
  • you do need A smtp server somewhere on the network but you do not need a third party SMTP server somewhere available to relay from (you can simply change the smtpserver variable from localhost to the name of the remote smtp server) if you are configuring and installing the smtp service locally. The technet doc I referenced is step by step for setting up the microsoft SMTP server (which is alot simpler than hmailserver) if you have specific questions with a step let me know where you are stuck.
    – Jim B
    Jul 7, 2010 at 14:46
  • ok Jim, where do I stuck? The issue is that I have 18 years old application and I can't change the code. I will post you tommorow which classes I'm using. My classes don't wnat to cooparate with IIS 7 and local smtp server. Jul 11, 2010 at 17:34
  • did it work with localhost on iis6?
    – Jim B
    Jul 12, 2010 at 12:27

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .