473,503 Members | 3,171 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

sending aspx as email

To send an aspx to email i use this code below:

Dim objMM As New MailMessage
Dim client As New System.Net.WebClient
Dim buffer() As Byte =
client.DownloadData("http://www.mysite.nl/mypage.aspx")
Dim str As String = System.Text.Encoding.ASCII.GetString(buffer)

objMM.BodyFormat = Web.Mail.MailFormat.Html
objMM.UrlContentBase = "http://www.mysite.nl"
objMM.From = "ne**@mysite.nl"
objMM.Subject = "MySite.nl news-update"
objMM.Body = str
objMM.BodyFormat = Web.Mail.MailFormat.Html

Dim x As Short
SmtpMail.SmtpServer = "my,smtpserver"

objMM.To = "someemailaddress"
SmtpMail.Send(objMM)
When i send this to a hotmail-account and open the email with msn the
layout of the email is a bit strange and not showing all the pic's.

When i get the same email with outlook/incredimail (pop3) it shows the right
layout.

Question: how to take care of msn. Perhaps when accessing the email with
webmail it will also be messed up ??
Richard Loupatty
Nov 18 '05 #1
3 1285
nowadays a lot of providers are starting to block the pictures
(unfortunately i think the img tags point to the pictures on your website)
as they are not a part of the email.
--
Regards,
HD
Once a Geek.... Always a Geek
"Richard Loupatty" <r.********@miodevelopment.nl> wrote in message
news:b7**************************@posting.google.c om...
To send an aspx to email i use this code below:

Dim objMM As New MailMessage
Dim client As New System.Net.WebClient
Dim buffer() As Byte =
client.DownloadData("http://www.mysite.nl/mypage.aspx")
Dim str As String =
System.Text.Encoding.ASCII.GetString(buffer)

objMM.BodyFormat = Web.Mail.MailFormat.Html
objMM.UrlContentBase = "http://www.mysite.nl"
objMM.From = "ne**@mysite.nl"
objMM.Subject = "MySite.nl news-update"
objMM.Body = str
objMM.BodyFormat = Web.Mail.MailFormat.Html

Dim x As Short
SmtpMail.SmtpServer = "my,smtpserver"

objMM.To = "someemailaddress"
SmtpMail.Send(objMM)
When i send this to a hotmail-account and open the email with msn the
layout of the email is a bit strange and not showing all the pic's.

When i get the same email with outlook/incredimail (pop3) it shows the
right
layout.

Question: how to take care of msn. Perhaps when accessing the email with
webmail it will also be messed up ??
Richard Loupatty

Nov 18 '05 #2
Hi Richard,
Thanks for posting in the community! My name is Steven, and I'll be
assisting you on this issue.
From your description, you use the Smtp class in dotnet framework to send
emails in your ASP.NET web application. However, you found that when you
view the mail you sent from your ASP.NET web apps in different mail
clients(such as OutLook or Hotmail...) , the displayed layout are somewhat
different. Some picutres missed in in MSN mail client, yes?
If there is anything I misunderstood, please feel free to let me know.

As for this problem, I'm sure it is due to he different mail clients
different treatment on the receiveing mails. Also, I agree with Hermit's
opinion that some mail clients may block certain picutures or other rich
element in the mail. Or some times some certain rich format emails will
also be displayed in different layout in different mail clients. So this
doesn't due to your code or the mail conetent you've sent. How do you think
of this?

In addtion, here is a tech article on this problem:
#Display Remote Images in a Message in Hotmail
http://email.about.com/cs/hotmailtips/qt/et080903.htm

Please check out the preceding suggestions. If you have any questions,
please feel free to let me know.
Regards,

Steven Cheng
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)

Nov 18 '05 #3
Steven,

Thanks, that's a warm welcome!
Even though this is not the first time i did a posting.

But i got the message now from both you and Hermit.
It's clarified now, thanks

Richard
Nov 18 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
6806
by: VB Programmer | last post by:
I have an ASPX page where I send out emails through my mail server mail.MyDomain.com. When I send emails to MyName@MyDomain.com it sends PERFECTLY. When I try sending an email to any other address...
2
1460
by: VB Programmer | last post by:
I'm encountering an error whenever I try to email people not in my domain. I get this error: The server rejected one or more recipient addresses. The server response was: 550 You must check...
5
3010
by: Vishal | last post by:
Hello, I already asked this question in the ASP.NET forums, but no help came. So I am hoping that somebody can help me out. This is really very URGENT me. For my e-commerce application, I...
1
8153
by: Eric Sheu | last post by:
Greetings, I have been searching the web like mad for a solution to my SMTP problem. I am using Windows Server 2003 and ASP.NET 2.0 w/ C# to send out e-mails from a web site I have created to...
0
773
by: yuv | last post by:
Hey guys, I have a aspx form that I use to send email. email is generated no proble, my question is how do I get the values entered by user in the mailit.aspx form to the mailit.cs file that is...
7
4375
by: Ray Booysen | last post by:
Hi all I'm sending email via ASP.NET in HTML mode. Each email has exactly one attachment and I do have full access to the SMTP server. However, if I send the email in HTML format, the...
3
4258
by: armando perez | last post by:
Hi, this is my first time here, but I was looking for something that may help me, and still, I haven't found something to use. I'm using a website made in .NET with C#, when I'm running my site...
6
11287
by: Rushwire | last post by:
Does anybody know how to send a meeting request using an ics/vcs (VCalendar) attachment from an asp.net page. I don't want my users to have to double click on the attachment but rather that it is...
3
1444
by: JJ297 | last post by:
Hello, After a user enters their request I'm sending a generated email to someone. How do I get that question to appear in the email? I have the link appearing in the email. This is what I...
8
3789
by: Marty | last post by:
I'm having issues sending an email to an "@page.nextel.com" email address. I can send to any other email address fine, but when I try the page.nextel.com it gives me this error: ...
0
7258
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
7313
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
6970
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
7441
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
1
4987
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
4663
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
3146
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
1489
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
1
720
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.