Hi
Ignition 7.8
I have a problem with sending a report through the mail. Every time the email is sent, it’s being sent without any data in it. I am using this script.
to = event.source.parent.getComponent('E_Mailadres_Text Field').text
path = event.source.parent.getComponent('Report Viewer').reportPath
report = event.source.parent.getComponent('Report Viewer')
Bakkerij = report.Bakkerij
Opmerkingen = report.Opmerkingen
StartDate = report.StartDate
EndDate = report.EndDate
system.report.executeAndDistribute(path = path, project = "Project",parameters = {"StartDate":StartDate, "EndDate":EndDate, "Bakkerij":Bakkerij, "Opmerkingen":Opmerkingen}, action = "email",
actionsettings = {"smtpServerName":"smtp", "from":"info@project.nl", "subject":"Leegdrukken Ringleiding Report", "attachmentName":"Leegdruk Ringleiding.pdf", "fileType":"pdf", "to":[to]})
I get this Error:
Time Logger Message
ERROR 16:13:25 Data [projectName=Project,reportPath=Leegdruk Ringleiding] Error gathering data for report
com.microsoft.sqlserver.jdbc.SQLServerException: The conversion from UNKNOWN to UNKNOWN is unsupported.
First I did use a different script with the function getBytes PDF but this function doesn’t longer exists.