ActiveX
To move data using the Clipboard
- If you do not want to include the row headers when you move data, and you do not want data pasted into the selected row headers, set the ClipboardOptions property to 0 (SS_CLIP_NOHEADERS).
- If you want to include the row headers when you move data, but you do not want data pasted into the selected row headers, set the ClipboardOptions property to 1 (SS_CLIP_COPYROWHEADERS).
- If you do not want to include the row headers when you move data, but you do want data to be pasted into the selected row headers, set the ClipboardOptions property to 2 (SS_CLIP_PASTEROWHEADERS).
- If you want to include the column headers when you move data, but you do not want data pasted into the selected column headers, set the ClipboardOptions property to 4 (SS_CLIP_COPYCOLHEADERS).
- If you do not want to include the column headers when you move data, but you do want data to be pasted into the selected column headers, set the ClipboardOptions property to 8 (SS_CLIP_PASTECOLHEADERS).
-
If you want a combination of moving column and row headers, you can Or the 1 (SS_CLIP_COPYROWHEADERS), 2 (SS_CLIP_PASTEROWHEADERS), 4 (SS_CLIP_COPYCOLHEADERS), and 8 (SS_CLIP_PASTECOLHEADERS) settings of the ClipboardOptions property as appropriate.
At design time, add the values for the settings and enter that numeric value to provide the following results:
ClipboardOptions
property settingCut row
headerPaste row
headerCut column header Paste column header 3 Yes Yes No No 5 Yes No Yes No 6 No Yes Yes No 7 Yes Yes Yes No 9 Yes No No Yes 10 No Yes No Yes 11 Yes Yes No Yes 12 No No Yes Yes 13 Yes No Yes Yes 14 No Yes Yes Yes Note: These property settings do not have a constant (SS_CLIP_xxxxx) associated with them. Just use the numeric Or value. -
If the AutoClipboard property is set to True, users can use the Clipboard shortcut keys to cut and paste data, or at run time,
- Call the SetSelection method to specify the cell or block of cells from which you want to cut data.
- Call the ClipboardCut method.
- Call the SetActiveCell or SetSelection methods to specify the cell or block or cells into which you want to paste the data.
- Call the ClipboardPaste method.