macro to use a cell's contents as it's name

S

Stephen Simons

Hi

I need a macro to use a cell's contents as it's name:

for example, if A1 contains the name "Fred Flintstone" I would like the macro to name cell A1 "Fred_Flintstone"

The cell reference will always be A1.

TIA

Steve
 
T

Tom Ogilvy

ActiveCell.Name = activeCell.Value

Make sure the value of the cell is a valid name. For example, no embedded
spaces.
--
Regards,
Tom Ogilvy

Stephen Simons said:
Hi

I need a macro to use a cell's contents as it's name:

for example, if A1 contains the name "Fred Flintstone" I would like the
macro to name cell A1 "Fred_Flintstone"
 
Top