ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Copy Cell and Paste in Same Column Only (https://www.excelbanter.com/excel-programming/323300-copy-cell-paste-same-column-only.html)

april

Copy Cell and Paste in Same Column Only
 
I have a spreadsheet that is protected from allowing users to copy and paste
in the spreadsheet as to prevent pasting cells over other with certain
formats. Is it possible for a user to copy a cell and paste within the the
same column (not including the header). This is the code is have to prevent
them from copying and pasting in general:

Private Sub Worksheet_SelectionChange(ByVal Target As Range)
Select Case Application.CutCopyMode = False
Case Is = False
MsgBox "You can not copy and paste."
End Select
Application.CutCopyMode = False
Application.CellDragAndDrop = False

End Sub

Thanks


All times are GMT +1. The time now is 07:49 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com