Jaafar Tribak
Well-known Member
- Joined
- Dec 5, 2002
- Messages
- 9,817
- Office Version
- 2016
- Platform
- Windows
Hi Guys,
I am trying to copy The Excel standard print icon on a userform command button that runs a printing procedure on clicking on it.
I have tried different approaches but without any luck.
The following code copies the icon on cell A1 of the activesheet:
Sub copy_faceid()
CommandBars(1).Controls(1).Controls("print...").CopyFace
ActiveSheet.Paste Cells(1, 1)
Application.CutCopyMode = False
End Sub
The approach above however, doesn't seem to work with userforms.
Any suggestions will be much appreciated as I have been like mad looking for a solution for a long long time.
Thanks.
Jaafar.
I am trying to copy The Excel standard print icon on a userform command button that runs a printing procedure on clicking on it.
I have tried different approaches but without any luck.
The following code copies the icon on cell A1 of the activesheet:
Sub copy_faceid()
CommandBars(1).Controls(1).Controls("print...").CopyFace
ActiveSheet.Paste Cells(1, 1)
Application.CutCopyMode = False
End Sub
The approach above however, doesn't seem to work with userforms.
Any suggestions will be much appreciated as I have been like mad looking for a solution for a long long time.
Thanks.
Jaafar.