Solved

ATTACH URL for file actaully on web not on local HDD

Posted on 2002-05-20
5
270 Views
Last Modified: 2012-05-04
Hi, I am using the following code

     dim xs
     xs = """" & "http://www.myURL.com/prodimg/" & rstProduct.fields.getValue("Image") & """"    
     Set myMail = CreateObject("CDONTS.NewMail")
     myMail.AttachURL xs , rstProduct.fields.getValue("Image")
     myMail.bodyFormat = 0
     myMail.mailFormat = 0
     myMail.From = "here@there.com"
     myMail.To = "craig@anyway.com"
     myMail.Subject = "TESTING"
     myMail.Body = HTML
     myMail.Send
     Set myMail = Nothing

I have the following code in the HTML build up

HTML = HTML & "<td width=304><img border=1 src=" & """" & rstProduct.fields.getValue("Image") & """" & " width=300 height=300></td>"

I am trying to get the image to be embeded into the mail so that it can viewed by the recipient without them having to be online, I keep getting a page cannot be displayed error from the server.... any ideas...

BTW what do I have to do to my local machine running PWS to be able to test this code, or does it need to run on an NT server for the CDONTS function to work, its a real pain having to upload the files to my ISP to test it.

Regards

Craig
0
Comment
Question by:publicityhouse
  • 2
5 Comments
 
LVL 5

Accepted Solution

by:
russellshome earned 100 total points
ID: 7021102
The recipient must be online in order to collect the email so your requirement "viewed by the recipient without them having to be online" seems nonsensical.

If the recipient has collected the email (online) and the image is specified using a fully qualified URL, the image will be cached so that recipient can view it offline anyway. You do not need to embed it.
0
 

Author Comment

by:publicityhouse
ID: 7021110
OK, so it may view again without going online, im gonna try the caching thing anyway :)
0
 
LVL 15

Expert Comment

by:gladxml
ID: 8836515
No comment has been added lately and it seems that this question have been abandoned. So it's time to clean up this TA.

I will leave a recommendation in the Cleanup topic area that this question or invite a Moderator to close this question if there's no reply from you after seven days.

In the absence of responses, I will recommend the following:

To accept the comment and points awarded to russellshome

** PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER **


Just trying to help for the cleanup...
gladxml
0
 
LVL 5

Expert Comment

by:russellshome
ID: 8859379
Good recommendation c|:-)
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

I have helped a lot of people on EE with their coding sources and have enjoyed near about every minute of it. Sometimes it can get a little tedious but it is always a challenge and the one thing that I always say is:  The Exchange of information …
Have you ever needed to get an ASP script to wait for a while? I have, just to let something else happen. Or in my case, to allow other stuff to happen while I was murdering my MySQL database with an update. The Original Issue This was written…
You have products, that come in variants and want to set different prices for them? Watch this micro tutorial that describes how to configure prices for Magento super attributes. Assigning simple products to configurable: We assigned simple products…
A company’s greatest vulnerability is their email. CEO fraud, ransomware and spear phishing attacks are the no1 threat to a company’s security. Cybercrime is responsible for the largest loss of money to companies today with losses projected to r…

929 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now