![]() |
Unable to set the Locked Property of the Range Class
In trying to solve the problems in my earlier post, I am
disabling addins, one by one, and have hit a problem. Using Tools Addins I attempt to disable one particular addin, and when I click OK I receive the above error. Debug takes me to this sequence: ElseIf (.Name = "SUMMARY" Or .Name = _ "GENERAL SUMMARY" Or .Name = "COVER" Or _ .Name = "CONTENTS") Then .Select .Unprotect .Cells.Locked = False ActiveSheet.UsedRange.Columns("A:G").Locked = True Set myRange = .UsedRange.Columns(6).Cells For Each Cell In myRange If Cell.Value = SEARCHFOR Then Cell.Offset(-1, -5).Locked = False End If Next where ActiveSheet.UsedRange is the highlighted line. 2 questions, please: Why does disabling this addin trigger code? Why the error message? Nb: the activeworkbook only has data in cols 1 to 5 !! Hence the error? This particular addin is the one I believe to be the root of the problem in my earlier post. It contains an Event Class module which I had expected would only operate on books opened by that addin. It may be that the event code is firing (quote) willy-nilly? Regards. Regards. --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.500 / Virus Database: 298 - Release Date: 10/07/2003 |
All times are GMT +1. The time now is 11:06 AM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com