Link to home
Start Free TrialLog in
Avatar of Varshini
Varshini

asked on

How to configure Exchange server email ?

I am using  SMTP for sending  email in  .net build application.
But recently one of my client  gave me the following exchange server details

Exchange server name :

and email id :

 asked me to use this in the application.

But my application not running in the  domain and the users using local machine login and using the application.

But i believe  that if i want to use the exchange server the machine should be login in the domain.
Is this  correct ?

What is different between using SMTP and Exchange server ?

Can i able to send email In my application if i use the exchange server name and email id without changing any coding ? OR i need to change the code for to use exchange server ?
Avatar of M A
M A
Flag of United States of America image

It is not necessary that the pc should be in domain to use exchange.
Just configure port 25 i.e. SMTP protocol which is used for sending email.
and configure authentication, That's it
Avatar of Varshini
Varshini

ASKER

client gave me the following details to configure EMAIL

Exchange server name :  exchange05.myserver.local

Email id : ersemail@aa.com
password : XXXXXXXX


But when i execute the following code

 
MailMessage message = new MailMessage("aaa@aaa.org","aaab@yahoo.com"," test","test");
    SmtpClient emailClient = new SmtpClient("exchange05.myserver.local");
 System.Net.NetworkCredential SMTPUserInfo = new System.Net.NetworkCredential("ersemail@aa.com","XXXXXXXX");
 emailClient.UseDefaultCredentials = false;
 emailClient.Credentials = SMTPUserInfo;
 emailClient.Send(message);
 
asp.net
<system.net>
    <mailSettings>
      <smtp from="ersemail@aa.com">
        <network host=" exchange05.myserver.local" port="25" userName="="ersemail@aa.com" password="XXXXXXXX"/>
      </smtp>
    </mailSettings>
  </system.net>




i got this error message :

Mailbox unavailable. The server response was: 5.7.1 Unable to relay

 please let me know how to fix this ?

Since my application using asp.net should i need to configure the SMTP in IIS7 ?

please let me know
This will answer your question I guess
http://forums.asp.net/t/1019543.aspx/1
Mailbox unavailable. The server response was: 5.7.1 Unable to relay
ASKER CERTIFIED SOLUTION
Avatar of M A
M A
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial