Microsoft Office Forums

Go Back   Microsoft Office Forums > >

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #5  
Old 06-16-2022, 05:35 AM
p45cal's Avatar
p45cal p45cal is offline Protect a column from row inserts or deletes Windows 10 Protect a column from row inserts or deletes Office 2019
Expert
 
Join Date: Apr 2014
Posts: 956
p45cal has a reputation beyond reputep45cal has a reputation beyond reputep45cal has a reputation beyond reputep45cal has a reputation beyond reputep45cal has a reputation beyond reputep45cal has a reputation beyond reputep45cal has a reputation beyond reputep45cal has a reputation beyond reputep45cal has a reputation beyond reputep45cal has a reputation beyond reputep45cal has a reputation beyond repute
Default

OK. Assuming that column A is the only column you want to protect, in the attached, is a bit of macro code behind Sheet4 which handles right-clicks on that sheet.
The idea is that you select a range or ranges on the sheet, then you right-click in one of the selected ranges and it will ask you whether you want to adjust all the selected ranges to right across the sheet but excluding column A. Whichever you choose the usual right-click menu will appear, and allow you to do what you intend with the selection.
As far as I'm aware, there's no way to protect a column from deletion of some of its rows while allowing the rest of the row to be deleted, hence the my code to adjust the selected cells before operating on them.
Attached Files
File Type: xlsm msofficeforums49207.xlsm (15.3 KB, 8 views)

Last edited by p45cal; 06-16-2022 at 02:00 PM.
Reply With Quote
 

Tags
freeze, lock

Thread Tools
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
How do I un-protect docs I didn't protect? doctorduncan Word 4 05-30-2019 11:09 AM
Protect a column from row inserts or deletes Ungrouping/grouping to protect document that deletes bookmark rng at contentcontrolonexit procedure madempress Word VBA 7 03-14-2018 03:14 PM
Protect a column from row inserts or deletes Document that inserts certain info Jamboy41 Word 1 11-14-2016 05:03 PM
a function that deletes all rows with no value in a certain column? dunndealpr Excel 2 06-08-2013 06:50 AM
Protect a column from row inserts or deletes Tracing Inserts DonH Word 9 05-18-2011 02:55 PM

Other Forums: Access Forums

All times are GMT -7. The time now is 03:25 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft