Dim WithEvents Img As MSHTML.HTMLImg
Private Sub UserForm_Initialize()
MultiPage1.Value = 0
LogoEmail.Navigate "about:<html><body><img src='" & ThisWorkbook.Path & "\Email3D.gif" & "' style='cursor: hand' /></body></html>"
End Sub
Private Sub LogoEmail_DownloadComplete()
On Error Resume Next
With LogoEmail.Document.body
.Style.backgroundcolor = RGB(223, 223, 223)
.Style.BorderStyle = "none"
.Scroll = "no"
End With
End Sub
Private Sub LogoEmail_DocumentComplete(ByVal pDisp As Object, URL As Variant)
On Error Resume Next
Set Img = LogoEmail.Document.images.Item(0)
End Sub
Private Function Img_onclick() As Boolean
With ThisWorkbook.Sheets("Feuil1").Range("A1")
If Not .Hyperlinks Is Nothing Then .Hyperlinks(1).Follow Else MsgBox "Aucun lien défini"
End With
Img_onclick = True
End Function
'//// Ajout PMO ////
Private Sub MultiPage1_Change()
If MultiPage1.SelectedItem.Caption = "Page1" Then
LogoEmail.Visible = True
Else
LogoEmail.Visible = False
End If
End Sub