I am looking for a solution where, when there is a state change, the VBScript sends an email to an email address defined in a metadata field, and the email should have an attachment of one file (e.g., Excel) attached to a multi-type document.
I've made it this far — I already receive the email, now I just need to attach the file associated with the document to the email.
Dim emailAdd emailAdd = PropertyValues.SearchForProperty(1105).Value.DisplayValue Dim oEmailMessage: Set oEmailMessage = CreateObject("CDO.Message") oEmailMessage.To = emailAdd oEmailMessage.From = "....." oEmailMessage.Subject = "Dokumentum értesítés" oEmailMessage.TextBody = "Csatoltan küldjük a dokumentumot." Dim oConf: Set oConf = oEmailMessage.Configuration oConf.Fields.Item("http://schemas.microsoft.com/cdo/configuration/sendusing") = 2 oConf.Fields.Item("http://schemas.microsoft.com/cdo/configuration/smtpserver") ="ip_adress..." oConf.Fields.Item("http://schemas.microsoft.com/cdo/configuration/smtpserverport") = 587 oConf.Fields.Update oEmailMessage.Send