How to modify script to open mail conversation instead of single email

hello Luc,

Hook Apple Email links opens only a single email. To open that email and view the whole conversation, one has to View - Show Related Messages

The script to do so is:

click menu item "Show Related Messages"  of menu 1 of menu bar item "View"  of menu bar 1 of application process "Mail"

How should I integrate (where should I copy the code above) into the Hook open Apple Mail script below ?

thank you !

set MessageID to text 9 thru -1 of MessageID

set MessageID to encodeText(MessageID, true, false)

tell application “Mail”
activate
try
set myurl to “open -a Mail “message:%3c” & MessageID & “%3e””
do shell script myurl
on error eStr number eNum
display dialog eStr & " Number: " & eNum buttons {“OK”} default button 1
return
end try
end tell

Also looking for a way to do this