Hi,
I'm using a flow to trigger when an email is received from a certain account.
It's a mail report and contains a few lines in the body but I'm only after part of one of them.
Report Id: 48aec5dd-f4fb-4c9a-9*******-*******
This email was automatically generated by the Generate Incident Report action.
Message Id: <************************************B11746.eurprd02.prod.outlook.com>
Sender: user1 name, user1@domain.co.uk
Recipients: user2@domain.co.uk
To: user2 name, user2@domain.co.uk
I want to extract the sender email address from this report and look it up against a Excel table. I have most of it working but the one issue I have is it extracting all of the sender, recipient and to details. so the lookup is failing.
After the trigger I have a step to convert HTML to Text and after that 2 steps to extract the date.
1st step is here
first(
split(
split(body('HtmlToText'), 'Sender:')[1],
'\n'
)
)
2nd step
toLower(
trim(
replace(
replace(
last(split(outputs('SenderLine'), ',')),
decodeUriComponent('%C2%A0'),
''
),
decodeUriComponent('%E2%80%8B'),
''
)
)
)
Can anyone advise where I've gone wrong?
Thanks