So far I have this.
Sub Macro1()
'
' Macro1 Macro
'
'
Range("E3").Select
ActiveWorkbook.Names.Add Name:="CGSF.COMUTIL.2", RefersToR1C1:= _
"=Sheet2!R3C5"
ActiveWorkbook.Names("CGSF.COMUTIL.2").Comment = ""
Range("F3").Select
ActiveWorkbook.Names.Add Name:="CGSF.DISTRATE.2", RefersToR1C1:= _
"=Sheet2!R3C6"
ActiveWorkbook.Names("CGSF.DISTRATE.2").Comment = ""
Range("G3").Select
ActiveWorkbook.Names.Add Name:="CGSF.CC.2", RefersToR1C1:="=Sheet2!R3C7"
ActiveWorkbook.Names("CGSF.CC.2").Comment = ""
Range("H3").Select
ActiveWorkbook.Names.Add Name:="CGSF.FUNCTION.2", RefersToR1C1:= _
"=Sheet2!R3C8"
ActiveWorkbook.Names("CGSF.FUNCTION.2").Comment = ""
End Sub
What I would like is to be able to provide a start column and an end column and then have the macro take the cell name and make it the range name for that cell.
Also is there a way to have add name:="" pull from the cell value instead of having to spell it out?