欧美一区二区三区,国内熟女精品熟女A片视频小说,日本av网,小鲜肉男男GAY做受XXX网站

Excel請問VBA怎樣實現清空剪貼板

林子帆2年前24瀏覽0評論

Excel請問VBA怎樣實現清空剪貼板?

VBA 參考代碼:

Option Explicit #If VBA7 Then Public Declare PtrSafe Function OpenClipboard Lib "user32" (ByVal hwnd As LongPtr) As Long Public Declare PtrSafe Function CloseClipboard Lib "user32" () As Long Public Declare PtrSafe Function EmptyClipboard Lib "user32" () As Long #Else Public Declare Function OpenClipboard Lib "user32" (ByVal hwnd As LongPtr) As Long Public Declare Function CloseClipboard Lib "user32" () As Long Public Declare Function EmptyClipboard Lib "user32" () As Long #End If Sub CallEC() Dim lngRet As Long lngRet = OpenClipboard(Application.hwnd) If lngRet Then EmptyClipboard CloseClipboard End If End Sub

先復制一段文字到剪貼板,然后運行 CallEC 過程,之后便會看到剪貼板被清空了。