Click here to Skip to main content
15,920,956 members
Home / Discussions / ASP.NET
   

ASP.NET

 
QuestionHow to set dynamic error message for custom validator Pin
NilCodeProject23-Oct-08 23:26
NilCodeProject23-Oct-08 23:26 
QuestionProblem with Ajax Tool and Validation Control Pin
gautamamit823-Oct-08 22:51
gautamamit823-Oct-08 22:51 
AnswerRe: Problem with Ajax Tool and Validation Control Pin
sumit703423-Oct-08 23:08
sumit703423-Oct-08 23:08 
QuestionLDAP Optional Parameters Pin
Hanumanth200023-Oct-08 21:28
Hanumanth200023-Oct-08 21:28 
Questionhow to pass values from one page to other page in post mechanism ? Pin
King Shez23-Oct-08 21:15
King Shez23-Oct-08 21:15 
AnswerRe: how to pass values from one page to other page in post mechanism ? Pin
John Gathogo23-Oct-08 21:30
John Gathogo23-Oct-08 21:30 
AnswerRe: how to pass values from one page to other page in post mechanism ? Pin
N a v a n e e t h23-Oct-08 21:32
N a v a n e e t h23-Oct-08 21:32 
QuestionLogin failed for user ''. The user is not associated with a trusted SQL Server connection. Pin
reogeo200823-Oct-08 21:08
reogeo200823-Oct-08 21:08 
AnswerRe: Login failed for user ''. The user is not associated with a trusted SQL Server connection. Pin
John Gathogo23-Oct-08 21:27
John Gathogo23-Oct-08 21:27 
GeneralRe: Login failed for user ''. The user is not associated with a trusted SQL Server connection. Pin
reogeo200823-Oct-08 23:43
reogeo200823-Oct-08 23:43 
GeneralRe: Login failed for user ''. The user is not associated with a trusted SQL Server connection. Pin
Ashfield24-Oct-08 1:47
Ashfield24-Oct-08 1:47 
QuestionAbout Mail Pin
kheer23-Oct-08 20:49
kheer23-Oct-08 20:49 
AnswerRe: About Mail Pin
simsen23-Oct-08 22:32
simsen23-Oct-08 22:32 
Hi kiranreddy,

Try this:

using System.Net.Mail;
protected void btnSendMessage_Click(object sender, EventArgs e)
{
   SmtpClient smtpClient = new SmtpClient();
   MailMessage message = new MailMessage();

   try
    {

        MailAddress fromAdress = new MailAddress("YourSenderEmail", "NameThatSendTheMessage");

        smtpClient.Host = "YoursmptClientHost";

        smtpClient.Port = 25; //Which port the smtpClient sends on

        message.From = fromAdress;

        message.To.Add("MailAdressToWhoShouldRecieveTheMail");
        message.Subject = "The message subject";

        message.IsBodyHtml = false;

        message.Body = "The message went here";

        smtpClient.Send(message);
        lblSendOk.Visible = true;
    }
    catch (Exception ex)
    {
        //Here I show an error, if any
        lblSendError.Visible = true;
        lblSendError.Text = lblSendError.Text + " .<br />" + ex.Message;
    }

}


If you have any trouble with the above code, you have to tell what exactly the error gives and copy your code, so we can see, if you have done anything else.

Kind regards,
simsen Smile | :)
AnswerRe: About Mail Pin
Abhijit Jana24-Oct-08 2:49
professionalAbhijit Jana24-Oct-08 2:49 
QuestionHow to convert System.Web.UI.WebControls.Table into System.Data.DataTable ? Pin
K V Sekhar23-Oct-08 20:26
K V Sekhar23-Oct-08 20:26 
AnswerRe: How to convert System.Web.UI.WebControls.Table into System.Data.DataTable ? Pin
Kannan Ar23-Oct-08 23:35
professionalKannan Ar23-Oct-08 23:35 
GeneralRe: How to convert System.Web.UI.WebControls.Table into System.Data.DataTable ? Pin
K V Sekhar24-Oct-08 3:04
K V Sekhar24-Oct-08 3:04 
AnswerRe: How to convert System.Web.UI.WebControls.Table into System.Data.DataTable ? Pin
Prasanna Kumar Pete23-Oct-08 23:42
Prasanna Kumar Pete23-Oct-08 23:42 
GeneralRe: How to convert System.Web.UI.WebControls.Table into System.Data.DataTable ? Pin
K V Sekhar24-Oct-08 3:05
K V Sekhar24-Oct-08 3:05 
QuestionHow to use Autocomplete TextBox in .net 2.0 without webservice? Pin
kandalu23-Oct-08 19:36
kandalu23-Oct-08 19:36 
AnswerRe: How to use Autocomplete TextBox in .net 2.0 without webservice? Pin
AhsanS23-Oct-08 20:13
AhsanS23-Oct-08 20:13 
GeneralRe: How to use Autocomplete TextBox in .net 2.0 without webservice? Pin
kandalu23-Oct-08 20:36
kandalu23-Oct-08 20:36 
AnswerRe: How to use Autocomplete TextBox in .net 2.0 without webservice? Pin
Abhijit Jana23-Oct-08 20:14
professionalAbhijit Jana23-Oct-08 20:14 
GeneralRe: How to use Autocomplete TextBox in .net 2.0 without webservice? Pin
kandalu23-Oct-08 20:41
kandalu23-Oct-08 20:41 
AnswerRe: How to use Autocomplete TextBox in .net 2.0 without webservice? Pin
N a v a n e e t h23-Oct-08 21:29
N a v a n e e t h23-Oct-08 21:29 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.