Add a new post


Name  
Email*  
Subject  
Message
 
 
Protected by Clearscreen.SharpHIPTo prevent abuse from bots, please enter the text you see.:
 

* In order to reduce SPAM, all email addresses will be obfuscated so they cannot be read by spam bots.
For example: 'test@test.com' will become 'test (at) test dot com'.

The specified protocol is unknown. Part 2
If you are getting this error, and you are adding attachments, you might be adding them incorrectly. You can only create a MailAttachment by specifying an absolute path.

For example, if you are doing something like:

MailAttachment a = new MailAttachment( "test.txt" );
m.Attachments.Add( a );

You will instead, need to explicitly specify the path. So try

MailAttachment a = new MailAttachment( Server.MapPath( "test.txt" ) ); //if this is an ASP.NET app
m.Attachments.Add( a );

or, from a console/winform app try

MailAttachment a = new MailAttachment( "c:\\test.txt" );
m.Attachments.Add( a );