Click here to Skip to main content
15,885,757 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Dear sir


I have created and excel file then i send it email in vb6 but when i open that mail there is only one option download but not view. if i download that file that does not open directly.
Firefox shows what is .xls .
I am using this code to send email

Set mg = CreateObject("CDO.Message")
Set iConf = CreateObject("CDO.Configuration")
Set fn = iConf.Fields
schema = "http://schemas.microsoft.com/cdo/configuration/"
fn.Item(schema & "sendusing") = 2
fn.Item(schema & "smtpserver") = "smtp.gmail.com" '"webmail.emailsrvr.com" '"smtp.gmail.com"
fn.Item(schema & "smtpserverport") = "465" '25 ' 465
fn.Item(schema & "smtpauthenticate") = 1
fn.Item(schema & "sendusername") = "thind.rajbirsingh@gmail.com"
fn.Item(schema & "sendpassword") = "thindrajbir"
With mg
To = "rajbir_thind@yahoo.com"
.To = "" & res("email") & ""
.From = "
<rajbir>
"
.Subject = "Sub: Quotation For the supply of CARTONS with respect of following specification:
"
.HTMLBody = "Please Download the attchment for Quotation "
'.Htmlbody = "Respected Sir/Madam ,

With reference to the above subject, we are pleasure to offer our lowest quotation for following products given by you:

"
.AddAttachment "" & tempPDFFileName & " "
Set .Configuration = iConf
SendEmailGmail = .Send
End With






Posted

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900