Hi, I'm very new to this VBA but have read Open All Hyperlinks in an Outlook Email Message posting. However, I'm looking for a way to open a very specific Hyperlink within an email usually following the word "Attachments" the name of the Hyberlinks differ each time. Or perhaps another way to go about is is to remove the other hyperlinks that don't pertain to the one I want by using this...
If Reg1.Test(olMail.Body) Then
Set M1 = Reg1.Execute(olMail.Body)
For Each M In M1
strURL = M.SubMatches(0)
If InStr(strURL, "unsubscribe") Then GoTo NextURL
If Right(strURL, 1) = ">" Then strURL = Left(strURL, Len(strURL) - 1
But I haven't been successful in removing the unwanted links
any help is much appreciated. Thanks!
If Reg1.Test(olMail.Body) Then
Set M1 = Reg1.Execute(olMail.Body)
For Each M In M1
strURL = M.SubMatches(0)
If InStr(strURL, "unsubscribe") Then GoTo NextURL
If Right(strURL, 1) = ">" Then strURL = Left(strURL, Len(strURL) - 1
But I haven't been successful in removing the unwanted links
any help is much appreciated. Thanks!