View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.misc
Ron de Bruin Ron de Bruin is offline
external usenet poster
 
Posts: 11,123
Default Command button to clear inputs

Typo Alert

Selction.ClearContents

Selection.ClearContents

For the OP
If you select the cells you want to clear with the CTRL key down you can give the cells a name with Ctrl-F3.

After that you can use
Range("YourRangeName").ClearContents



--

Regards Ron de Bruin
http://www.rondebruin.nl/tips.htm


"Gord Dibben" <gorddibbATshawDOTca wrote in message ...
You need to supply some more details to get anything other than a few guesses.

What "inputs" need to be cleared and when?

Sub Clearit()
Selction.ClearContents
End Sub

Will clear all data from the selected cells.

The Delete key will do the same thing.

Why do you think you need a macro?


Gord Dibben MS Excel MVP


On Mon, 2 Apr 2007 12:36:04 -0700, mbing916
wrote:

Could you help me with the macro so I could assign a button to clear inputs?
Is there a place to go to look up different macros? I don't have much
experience with this and it is hard to know what to put so the macro will
work.

Thanks!