SMTP trouble with Sams asp.net in 24 hours

omichmelanie

New Member
I probaly should have been less ambitious and bought the '21 days' book :)<BR><BR>Anyhow, I'm workign through sams 'ASP.NET in 24 hours' and have hit a stumbling block early on. Following one of the first examples exactly I've got a page witht he first line<BR><BR>"<%@ Import NameSpace="System.Web.Mail.SMTPMail" %>"<BR><BR>Then further down I've got<BR><BR>"<%DIM objSMTP as New System.Web.Mail.SmtpMail()"...<BR><BR>And when accessed I'm getting<BR><BR>"Compiler Error Message: BC30390: 'System.Web.Mail.SmtpMail.Private Overloads Sub New()' is not accessible in this context because it is 'Private'."<BR><BR>Anybody come across this? I'ts my first stab at asp.net/vb.net and I'm stumped.This code is Beta 2 code, IIRC (or maybe Beta1 code). In any case, you need to use the namespace System.Web.Mail, using the classes SmtpMail and MailMessage. See ms-help://MS.VSCC/MS.MSDNVS/cpref/html/frlrfSystemWebMail.htm for the docs, or read: http://www.4guysfromrolla.com/webtech/080801-1.shtml<BR><BR>Happy Programming!Cheers Scott, I've ended up using the code from your tute and I'll repurpose the rest of the book as I go along I guess...<BR><BR>Thanks again<BR>Daniel
 
Back
Top