ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Deleting data but not formula (https://www.excelbanter.com/excel-programming/310323-re-deleting-data-but-not-formula.html)

Tom Ogilvy

Deleting data but not formula
 
assume data is entered in the range B9:G30 and some of the cells may have
formulas, but don't contain labels you want to retain.

on Error Resume Next
range("B9:G30").SpecialCells(xlConstants).Clearcon tents
On Error goto 0

--
Regards,
Tom Ogilvy

"La Durande" wrote in message
...
Am using a template to produce invoices and after saving the finished

invoice
as aa xls I require to clear the template in order to produce the next
invoice without having to close (without saving) & then reopen the

template.




All times are GMT +1. The time now is 06:47 AM.

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