• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

How to make a clear button to clear some selected Cells

mmsamaddar

New Member
Good afternoon,

Need Help: I have a sheet with too many workings (formula) and I have made it password protected. In this sheet, I have some cell to edit or input some data that will make a result. The editable cell is C14:E44, D4, H14:G44, K5. But rest of the cell is fully protected. Here I need a button for clear those cell by one click in Excel 2010 or select all those cell with the help of hyperlink as Select as Delete with that one click.
Can you help?
Regards,
Madhu
 
Hi,
I tried this as Bob advised:

Code:
Sub Macro1()
    Range("D4,K5,C14,E44,G44").Select
    Selection.ClearContents
    Application.Goto [a1]
    End Sub

Make a button or shape > right click > select assign macro > Macro1

Regards,
 
Hi,
I tried this as Bob advised:

Code:
Sub Macro1()
    Range("D4,K5,C14,E44,G44").Select
    Selection.ClearContents
    Application.Goto [a1]
    End Sub

Make a button or shape > right click > select assign macro > Macro1

Regards,
I have also input a code for another purpose. If I want to add this code to the existing code, what should I do?
 
If you post on multiple forums it is good manners to inform members on all forums that you are doing so.
Members are giving their time for free to help you and do not realise you are get the answer from another forum and you are wasting their time.


.
 
Back
Top