Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi all,
I know it's been discussed few times but I can't figure out why I fail to send mail through Qlikview.
I stripped the code down to just necessary lines and the macro editor jumps when the send command is executed, thus failing to send the mail.
function sendme()
set objMessage = CreateObject("CDO.Message")
objMessage.Subject = "Subject"
objMessage.From = "eliran@gmail.com"
objMessage.To="xxxx@gmail.com"
objMessage.TextBody="testing Body"
objMessage.Configuration.Fields.Item _
("http://schemas.microsoft.com/cdo/configuration/sendusing") = 2
objMessage.Configuration.Fields.Item _
("http://schemas.microsoft.com/cdo/configuration/smtpserver") = "smtp.gmail.com"
objMessage.Configuration.Fields.Item _
("http://schemas.microsoft.com/cdo/configuration/smtpserverport") = 587
objMessage.Configuration.Fields.Update
objMessage.Send
end function
Thanks for any help,
Eliran.
Hi Miguel,
I'm afraid the same thing happens when I try your code, the code ObMsg.Send is highlighted and the macro is failing.
Am I missing something else?
Regards,
Eliran.
Hi,
Does your computer have some firewall, antivirus software that is avoiding qv.exe from sending emails? The code itself works using your own username and password. If it doesn't I'd think of:
1.- Macro permissions: Go to the macro editor, and Allow System Access
2.- External software preventing QlikView sending emails.
Hope that helps.
Thanks Miguel,
My firewall blocked it.
Regards,
Eliran.
Hi Miguel, can you re-post your code? I can't open the link.
Thank you very much.
Roby
Hi Roby,
Check this post. I'll change the post above that points to the old QlikCommunity files.
Hope that helps.
BI Consultant
Thank you very much !
Roby