Sub Test()
ClearPressePapier
If PressePapier = "" Then MsgBox "Non"
PressePapier = "toto"
MsgBox PressePapier
End Sub
Public Function ClearPressePapier()
CreateObject("htmlfile").parentwindow.clipboardData.clearData "Text"
End Function
Public Property Let PressePapier(valeur)
CreateObject("htmlfile").parentwindow.clipboardData.setData "Text", valeur
End Property
Public Property Get PressePapier()
PressePapier = "" & CreateObject("htmlfile").parentwindow.clipboardData.GetData("TEXT")
End Property