Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Copy & paste image from UserForm
Hi pmartin,
You can try: Private Declare Function OpenClipboard& _ Lib "user32" (ByVal hwnd&) Private Declare Function EmptyClipboard& _ Lib "user32" () Private Declare Function SetClipboardData& _ Lib "user32" (ByVal wFormat&, ByVal hMem&) Private Declare Function CloseClipboard& _ Lib "user32" () Private Sub Image1_MouseDown(ByVal Button% _ , ByVal Shift%, ByVal X!, ByVal Y!) If Button = 2 Then On Error GoTo Bug Application.CommandBars.FindControl(ID:=809).Execu te Dim hCopy& OpenClipboard 0& EmptyClipboard hCopy = SetClipboardData(2, Me.Image1.Picture.Handle) CloseClipboard Me.Image1.Picture = LoadPicture("") Me.Repaint End If Bug: End Sub MP a écrit dans le message de news: ... Hi all Is there an easy way to enable cut & paste from an image on a UserForm (to another app, say Word). I have an Image control that displays a chart GIF. I would like the user to be able to right-click and cut & paste in the usual Windows manner. Are there some APIs that enable this? Thanks in advance Paul Martin Melbourne, Australia |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Copy and paste an image | Excel Discussion (Misc queries) | |||
How to embed an image withon a cell as opossed to copy and paste | Charts and Charting in Excel | |||
copy shape image into image control | Excel Programming | |||
Copy image of UserForm to a clipboard | Excel Programming | |||
copy-paste in a userform | Excel Programming |