Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi friends,
There is pivot table, which I need to send every day to others people.
Is it possible to automate this process?
Thanks.
Yes. You can use the search function to find discussions about this subject: http://community.qlik.com/search.jspa?q=email+report
Hi,
It is posible, and you have to do it using MACRO.
First of alla you have to export to excel or pdf and then you have to send to email with the atached element
try with this script
----------------------------------------------------------------------------------------------------------------------------------------------------
SendGMail
ActiveDocument.Save
set objExcel=nothing
set strDate=nothing
set filepath=nothing
End Sub
Sub SendGMail()
MsgBox "Report Exported Successfully"
strDate = Year(Date()) &"-"& month(date()) &"-"& Day(Date())
filepath="D:\Excel_"&strDate&".xls"
Set objMsg = CreateObject("CDO.Message")
Set msgConf = CreateObject("CDO.Configuration")
'Server Configuration
msgConf.Fields.Item("http://schemas.microsoft.com/cdo/configuration/sendusing") = 2
msgConf.Fields.Item("http://schemas.microsoft.com/cdo/configuration/smtpserver") = "smtp.gmail.com"
msgConf.Fields.Item("http://schemas.microsoft.com/cdo/configuration/smtpserverport") = 25
msgConf.Fields.Item("http://schemas.microsoft.com/cdo/configuration/smtpauthenticate") = 1
msgConf.Fields.Item("http://schemas.microsoft.com/cdo/configuration/sendusername") = "500vikas@gmail.com"
msgConf.Fields.Item("http://schemas.microsoft.com/cdo/configuration/sendpassword") = "**********" 'Type your acccount Password
msgConf.Fields.Item("http://schemas.microsoft.com/cdo/configuration/smtpusessl") = 1
msgConf.Fields.Update
'End With
objMsg.To = "Sender Mail ID"
objMsg.From = "Xyzz@gmail.com"
objMsg.Subject = "Test mail"
objMsg.HTMLBody = "QlikView Test Mail"
'objMsg.AddAttachment "D:\Image.jpg"
objMsg.AddAttachment filepath ' Attachement
objMsg.Sender = "Mr. Name"
Set objMsg.Configuration = msgConf
' Send
objMsg.Send
Msgbox("Email Sent Successfully")
' Clear
Set objMsg = nothing
Set msgConf = nothing
End Sub
-----------------------------------------------------------------------------
Just edit your mail and password and all the server smtp information
I attached another example as export to pdf and excel
http://luciancotea.wordpress.com/2013/07/18/qlikview-macros-useful-collection/
good luck!
FERNANDO
Hi.
Yes it's possible.
I guess that you've already found something useful here. Anyway, you can start from this http://community.qlik.com/docs/DOC-3772
WHERE TO RUN THIS MACRO?
I NEED TO RUN IN QLIKVIEW APPLICATION (CNTRL + M)?