I get the following error message on the .SendCode:MailAddress SendFrom = new MailAddress("[email protected]"); MailAddress SendTo = new MailAddress(To); MailMessage MyMessage = new MailMessage(SendFrom, SendTo); MyMessage.Subject = subject; MyMessage.Body = message; SmtpClient emailClient = new SmtpClient("127.0.0.1"); emailClient.DeliveryMethod = SmtpDeliveryMethod.PickupDirectoryFromIis; emailClient.PickupDirectoryLocation = "C:\\Inetpub\\mailroot\\Pickup\\"; emailClient.Send(MyMessage);
Cannot get IIS pickup directory.
The directory exists and it occurs with or without me specifiying emailClient.PickupDirectoryLocation
There is an SMTP server on the box and its running. Its a fasthosts dedicated box if that makes a differnence.
Any suggestions?




Reply With Quote