Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello,
I use the SMTP Connector on a Qlik Sense Enterprise Desktop Version. I want to send data via mail. On Reload the mail is sent, but it won't let me send data.
I want to append it to the message variable. If that ain't possible (what I'm expecting, because it just accepts strings), I want to send a file via the fileAttachement variable. I linked the path, but my mail still has no attachment.
Yes, I will check the path again. But is there anything else I can do or are there any tricks?
Hi!
There are some troubleshoot you can do, first check the file path is absolute and accessible by the Qlik Sense environment, then try placing the file in a different directory where Qlik Sense has full access. Also check there are no special characters or spaces in the path that could cause issues.
I know some SMTP connectors may only support certain file types (e.g., .txt, .csv, .xlsx), can you try sending a simple .txt file as a test?
In some cases, the attachment variable might require a full UNC path (e.g., \\server\folder\file.txt) instead of a local path (C:\folder\file.txt).
Finally if Qlik Sense is running on a server, double check the file exists on the same machine or is accessible via a network path.
Hi,
thanks for your answer! I tried all of the above steps, even sending a .txt
Qlik Sense is running on a server and I tried to send the file via full UNC path and local path, still no result sadly.
Is there by any chance the possibility to create a HTML from the script to avoid using the optional fileAttachment variable? So like using the message variable instead?
Still, many thanks so far!
Hi!
Maybe could be a permission problem, if Qlik Sense is running as a service, can you check the service account's permissions on the file? You can try placing the file in C:\Temp\ or another directory where the Qlik Sense service has full access.
To embed data in messageas an HTML table:
try
message="<html><body><h2>Data Report</h2><table border='1'><tr><th>Column1</th><th>Column2</th></tr><tr><td>Value1</td><td>Value2</td></tr></table></body></html>"
Ensure html='true' is set in WITH PROPERTIES.
Did you succeed? regards,
Diego
Yes, I had to to a loop and abuse the Peek-function to create my HTML from a table, afterwards I connected my string from multiple variables into one variable. I had to do it, because the message parameter only accepts one string and doesn't let me concat multiple variables.
My HTML still didn't work, because of the concatenation of the string variables, there where multiple " ' " in my HTML. That's why I loaded into into one field of table and replaced the string. Afterwards I passed the field into a variable again and passed it to the message parameter. That's when it worked!