How do I reference a single field containing multiple short name entries as a source to send email

Hello hoping someone can help.

I have a lotus notes database which sends alerts via email it works well if only one lotus notes short name is in the lookup table field  however if multiple shortnames are placed in the single field (LineManager) separated by a ; it seems lotus notes can not send the email. I have ensured the names field (LineManager) is set to allow multiple values but still no good.

AS mentioned the code works for single entries, it is more how do I tell lotus the field has multiple values and send an email to each entry ?


@If(Status2="" & IncidentClass !="NM";@MailSend(TestRev:Safety3:LineManager:FuncManager; "";"";IncidentName + "New safety Incident logged  - " + @Text(IncidentClass);"";@Text(Category) + "Incident: " +@Text(Counter) + " " + RiskDescription + @NewLine + Incident + @NewLine + @NewLine;[IncludeDoclink]);"");
ianmcalderAsked:
Who is Participating?
 
Sam654Commented:
Have a look at what LineManager returns on it's own using an @Prompt, I expect it's only returning a single string, then look at using @Explode to seperate them into a list.
0
 
mbonaciCommented:
It should work by just specifying field name in the place of SendTo parameter.
In the place of that param (and all other address params) @MailSend expects multiple values in a format of text list:
    "mark@smallcompany.com" : "miro@bigcompany.com" : "anita@bigcompany.com"

which is exactly how multi-value fields store their values.

Examine field value in document properties:
    Right click on document > Document properties > second tab

and report findings here.
0
 
Sjef BosmanGroupware ConsultantCommented:
Setting the field to Multiple values in the form won't change the existing documents. If the fields in there were one string only, with multiple addresses, they still are after changing the form.
0
 
ianmcalderAuthor Commented:
Hi thnks for you help it was in fact returning a single string
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.