Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
To the Great and Wise VBA Gurus,
Is there a VBA routine that would "clear contents" out of all th unprotected cells on a worksheet, that could use the "UsedRange property so that it could be utilized on worksheets of differin sizes? Many thanks in advance Case -- Message posted from http://www.ExcelForum.com |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Casey
Try this.....clears contents of unlocked cells on all worksheets. Adapt to suit. Sub UnlockedCells() Dim wk As Worksheet Dim cl As Range For Each wk In Worksheets For Each cl In wk.UsedRange If cl.Locked = False Then cl.ClearContents End If Next Next End Sub Gord Dibben Excel MVP On Thu, 5 Aug 2004 17:31:08 -0500, Casey wrote: To the Great and Wise VBA Gurus, Is there a VBA routine that would "clear contents" out of all the unprotected cells on a worksheet, that could use the "UsedRange" property so that it could be utilized on worksheets of differing sizes? Many thanks in advance Casey --- Message posted from http://www.ExcelForum.com/ |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Gord,
A million thanks, our internet access has been down and I couldn't ge back here to see if any one had replied. I try not to ask for cod without a least first trying something on my own. But this was kind o an emergency and you have made my day. Again, thank you Case -- Message posted from http://www.ExcelForum.com |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
"Do you want to replace the contents of the destination cells?" | Excel Discussion (Misc queries) | |||
Problems with macro, setting "tab order" of unprotected cells | Excel Discussion (Misc queries) | |||
Adding the contents of "x" number of cells. | Excel Worksheet Functions | |||
how to increase size of "name box" and "contents of cell " displa. | New Users to Excel | |||
Clearing Unprotected Cells | Excel Programming |