Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I am using Excel 2002 and have a sheet which Ranges from E5:O78.
There are 20 ranges like E5:F18, H5:F18 etc which has only input info as in a time sheet. I need to delete the info with a macro but need to keep the Formulas outside these Ranges intact. I have been successfully using: ActiveSheet.Unprotect Range("E5:F18,H5:I18,K5:L18,etc................... .).ClearContents ActiveSheet.Protect but the formula length become unwieldy with 20 Ranges to clear, is there one Formula which will only delete non formula cells? Many thanks Jim |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Select the range E5:L18 for example
Press F5 click on special choose constants press the delete key Or with VBA Range("E5:L18").SpecialCells(xlCellTypeConstants). ClearContents -- Regards Ron de Bruin (Win XP Pro SP-1 XL2002 SP-2) www.rondebruin.nl "Jim" wrote in message .. . I am using Excel 2002 and have a sheet which Ranges from E5:O78. There are 20 ranges like E5:F18, H5:F18 etc which has only input info as in a time sheet. I need to delete the info with a macro but need to keep the Formulas outside these Ranges intact. I have been successfully using: ActiveSheet.Unprotect Range("E5:F18,H5:I18,K5:L18,etc................... .).ClearContents ActiveSheet.Protect but the formula length become unwieldy with 20 Ranges to clear, is there one Formula which will only delete non formula cells? Many thanks Jim |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Many thanks Ron, much easier!!
"Ron de Bruin" wrote in message ... Select the range E5:L18 for example Press F5 click on special choose constants press the delete key Or with VBA Range("E5:L18").SpecialCells(xlCellTypeConstants). ClearContents -- Regards Ron de Bruin (Win XP Pro SP-1 XL2002 SP-2) www.rondebruin.nl "Jim" wrote in message .. . I am using Excel 2002 and have a sheet which Ranges from E5:O78. There are 20 ranges like E5:F18, H5:F18 etc which has only input info as in a time sheet. I need to delete the info with a macro but need to keep the Formulas outside these Ranges intact. I have been successfully using: ActiveSheet.Unprotect Range("E5:F18,H5:I18,K5:L18,etc................... .).ClearContents ActiveSheet.Protect but the formula length become unwieldy with 20 Ranges to clear, is there one Formula which will only delete non formula cells? Many thanks Jim |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Keep sheet from deleting contents | Excel Worksheet Functions | |||
Clairification in finding and deleting cells from one sheet to ano | Excel Discussion (Misc queries) | |||
finding and deleting cells from one excel sheet to another | Excel Discussion (Misc queries) | |||
Deleting every-other row in a spread sheet | Excel Discussion (Misc queries) | |||
Deleting a Sheet | Excel Programming |