Click here to Skip to main content
15,896,606 members
Home / Discussions / C#
   

C#

 
QuestionHow to convert a PDF document to JPG. Pin
Exelioindia8-Oct-07 0:48
Exelioindia8-Oct-07 0:48 
AnswerRe: How to convert a PDF document to JPG. Pin
Christian Graus8-Oct-07 1:12
protectorChristian Graus8-Oct-07 1:12 
GeneralRe: How to convert a PDF document to JPG. Pin
Exelioindia8-Oct-07 2:28
Exelioindia8-Oct-07 2:28 
GeneralRe: How to convert a PDF document to JPG. Pin
Pete O'Hanlon8-Oct-07 2:43
mvePete O'Hanlon8-Oct-07 2:43 
QuestionWindowsPrincipal object gives null value for username when checked in component Pin
Naveen S H8-Oct-07 0:41
Naveen S H8-Oct-07 0:41 
QuestionWhere will be the assembly stores in the System Pin
pashitech8-Oct-07 0:40
pashitech8-Oct-07 0:40 
AnswerRe: Where will be the assembly stores in the System Pin
Pete O'Hanlon8-Oct-07 1:45
mvePete O'Hanlon8-Oct-07 1:45 
QuestionError while using System.Net.Mail.SmtpClient to send mail Pin
A M SOMAN7-Oct-07 22:59
A M SOMAN7-Oct-07 22:59 
I am trying to send a mail through my console application which is in .Net 2.0 with C# language. I am using the class System.Net.Mail.SmtpClient to send a mail. This was decided because the older version of this class System.Web.Mail.SmtpMail is now totally obsolete.
But I get an error message as "Failure sending mail." when I run my code.
I tried to resolve this by following:
1. Tried pinging the address from command prompt. It shows reply.
2. Assigned port number as number 25. Doesn't work. Gives same error.
Following is my code

FromEmail = "anil.soman@xyz.com";
strEmailAddre = "somebody@xyz.com";
strSubject = "some subject";
strBody = "some text for body";
System.Net.Mail.SmtpClient SMTPClient = new System.Net.Mail.SmtpClient();
SMTPClient.Host = "smtpservername";
SMTPClient.Port = 25;
SMTPClient.Send(FromEmail, strEmailAddre, strSubject, strBody);

What could be the reason for this? Any suggessions? Thanks in advance.



Regards,
Anil
AnswerRe: Error while using System.Net.Mail.SmtpClient to send mail Pin
Andrei Ungureanu7-Oct-07 23:23
Andrei Ungureanu7-Oct-07 23:23 
GeneralRe: Error while using System.Net.Mail.SmtpClient to send mail Pin
A M SOMAN8-Oct-07 0:49
A M SOMAN8-Oct-07 0:49 
GeneralRe: Error while using System.Net.Mail.SmtpClient to send mail Pin
Andrei Ungureanu8-Oct-07 1:02
Andrei Ungureanu8-Oct-07 1:02 
QuestionHandling Text data taken from file Pin
rsaint277-Oct-07 22:54
rsaint277-Oct-07 22:54 
AnswerRe: Handling Text data taken from file Pin
Andrei Ungureanu7-Oct-07 23:27
Andrei Ungureanu7-Oct-07 23:27 
GeneralRe: Handling Text data taken from file Pin
rsaint278-Oct-07 0:09
rsaint278-Oct-07 0:09 
GeneralRe: Handling Text data taken from file Pin
Andrei Ungureanu8-Oct-07 0:48
Andrei Ungureanu8-Oct-07 0:48 
GeneralRe: Handling Text data taken from file Pin
rsaint278-Oct-07 0:59
rsaint278-Oct-07 0:59 
JokeRe: Handling Text data taken from file Pin
Andrei Ungureanu8-Oct-07 1:03
Andrei Ungureanu8-Oct-07 1:03 
QuestionOperator @ Masked textbox [modified] Pin
G. Mathu7-Oct-07 22:54
G. Mathu7-Oct-07 22:54 
AnswerRe: Operator @ Masked textbox Pin
Seishin#7-Oct-07 22:59
Seishin#7-Oct-07 22:59 
Questionvariable as type of generic (method) Pin
Seishin#7-Oct-07 22:50
Seishin#7-Oct-07 22:50 
AnswerRe: variable as type of generic (method) Pin
Eduard Keilholz8-Oct-07 2:16
Eduard Keilholz8-Oct-07 2:16 
GeneralRe: variable as type of generic (method) Pin
Seishin#8-Oct-07 2:20
Seishin#8-Oct-07 2:20 
GeneralRe: variable as type of generic (method) Pin
Guffa8-Oct-07 2:35
Guffa8-Oct-07 2:35 
QuestionBinary Equals Pin
Patricio Tapia7-Oct-07 21:55
Patricio Tapia7-Oct-07 21:55 
AnswerRe: Binary Equals Pin
Andrei Ungureanu7-Oct-07 22:35
Andrei Ungureanu7-Oct-07 22:35 

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.