A clear button that will clear certain cells on all sheets

WebMistress

New Member
Joined
Nov 25, 2003
Messages
12
Does anyone know the code for doing this? I know it's most likely going to be a VB code.

I have 7 worksheets and I need several cells in each worksheet that need to be cleared when a button is pressed on the first sheet.

Thanks. :biggrin:
 

Excel Facts

Round to nearest half hour?
Use =MROUND(A2,"0:30") to round to nearest half hour. Use =CEILING(A2,"0:30") to round to next half hour.
Re: A clear button that will clear certain cells on all shee

Thanks I will see if that fixs what I need for my spread sheets :LOL:
 
Upvote 0
What I did was... I went though the whole spread sheet and renamed the areas to rg1-10 then I made MasterClearList=rg-10 and created a button.

What is wrong with the following code? It's asking me to debug.


Private Sub CommandButton1_Click()
Range("MasterClearList").ClearContents
End Sub
 
Upvote 0

Forum statistics

Threads
1,214,376
Messages
6,119,181
Members
448,871
Latest member
hengshankouniuniu

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top