PDA

View Full Version : ASPNetEmail not working


patrudu_k
11-12-2004, 04:12 AM
I am using ASPNetEmail component in one of my aspx pages. It was working fine for quite some time. But now, for the last 3 days, I think after the upgradation of the component, it is giving the following eror message :


'The type or namespace name 'aspNetEmail' could not be found (are you missing a using directive or an assembly reference?)'



I am using the following code snippet in the aspx page:



<script language='C#' runat='server'>
public void SendMailAndRegister_Clicked(object sender, EventArgs e){



aspNetEmail.EmailMessage msg = new aspNetEmail.EmailMessage();
msg.ValidateAddress = false;
msg.Server = 'localhost';
msg.FromAddress = 'info@xyz.com';
msg.FromName = 'abc';
msg.To = email.Text;
msg.Subject = 'abc';
msg.ConfirmRead = true;
msg.ReturnReceipt = true;
msg.HtmlBodyPart ='Message here';
msg.WordWrapLen = 45;
if ( msg.Send() ){
Msg.InnerHtml='Thank you for the details.';
}else{
Msg.InnerHtml='<font face=vardana size=-1 color=darkred >[b]The following error occurred:' + msg.LastException().Message +'</font>[b][b][b][b][b][b]';
}

}
</script>





The above code is working fine on my local m/c with demo ASPnetEmail installed.

Post Edited (patrudu_k) : 4/13/2008 6:18:57 PM GMT

bruce
11-12-2004, 11:37 AM
Add this line to your aspx page

<%@ Assembly name='aspNetEmail, Version=3.0.0.0, Culture=neutral, PublicKeyToken=bc571e8da1c1f543' %>

Bruce

DiscountASP.NET
www.DiscountASP.NET (http://www.DiscountASP.NET)

patrudu_k
11-13-2004, 09:01 AM
Now it works! But the earlier version was working without this. You mentioned in your mail "This is a side by side installation so most applications using the older versions should not experience any issues." And so I did not bother to check. Because of this, the download page of my web site was dead for 3/4 days.

bruce
11-15-2004, 10:44 AM
We changed the way ASPEmail, ASPPoP, ASPMIME are installed. We notified all users through the component update email list that old code may break.

Did you subscribe to our component email list? We recommend everyone that use any of the preinstalled components subscribe to this list. You can do that in the control panel (right hand navigation)

Bruce

DiscountASP.NET
www.DiscountASP.NET (http://www.DiscountASP.NET)

patrudu_k
11-16-2004, 02:38 AM
Yes. I subscribed. In fact, I was referring to
the same email in my post and quote was alsofrom the same email.

Eric
11-16-2004, 03:35 AM
Most customers did not experience any issues with the side by side install. Some customers did. Due the the frequency of componentupgrades, both minor and major, we had to change the way the components are installed. All our knowledge base articles were updated for some time now. You may have been using old code from the original knowledge base articles(?)


DiscountASP.NET
http://www.DiscountASP.NET