Convert System.String to IEnumerable(MailMessage)

Hi,

One of my collabs want to use “For each Email” and use variable (from asset) for the label path. But the label path type is “IEnumerable(MailMessage)”. We already trying to change variable type to IEnumrable but it doesn"t work.

Someone can help us ?

Thanks

1 Like

Hi @Christopher_p

can you share your workflow here

1 Like

Hi,

She send me his workflow, concerned activities :

The Get Asset and initializing variable :
image
But Get Asset give a String variable

The variable with Ienumerable(MailMessage) :
image
And it’s an error because can’t convert String to IEnumerable

The For Each Emails with folderMail :
image

I hope i don’t forget anything

1 Like

I think @Christopher_p the asset value is type of string and you need to convert in IEnumerable. You have to split the text of asset type value and then need to pass in For each email. You can try this option

1 Like

Yes because on Orchestrator we have only “Text” or “Credential”. But the “For Each Email” want "IE numerable(MailMessage), so i don’t know how we can convert… Sorry for my bad level :confounded:

1 Like

Have you tested with Outlook.Folder(folderMail)? (Where Outlook is the reference name you set in the Use X card scope.

1 Like

@ptrobot that’s work ! Thanks for your help !

Have a nice day

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.