Results 1 to 2 of 2

Changing the name of a Defined List in Name Manager using VBA?

Threaded View

cool1_boy1 Changing the name of a... 04-22-2013, 07:32 PM
davesexcel Re: Changing the name of a... 04-22-2013, 09:43 PM
  1. #1
    Registered User
    Join Date
    03-19-2013
    Location
    Canada
    MS-Off Ver
    Excel 2010
    Posts
    27

    Changing the name of a Defined List in Name Manager using VBA?

    So I have:
    Sub DefineCableType()
    
        ActiveWorkbook.Names.Add Name:="Size_" & "CELL NAME", RefersToR1C1:="=offset(R2C" & ActiveCell.Column & ",0,0,COUNTA(R2C" & ActiveCell.Column & ":R90C" & ActiveCell.Column & ")-COUNTBLANK(R2C" & ActiveCell.Column & ":R90C" & ActiveCell.Column & ")+1,1)"
        
    End Sub
    What I want is that when the active cell is selected (ex. Assuming cell O1 is the active cell and its contents are COOKIES), the contents of that cell are named to CELL NAME. This means that the name of my list will now be Size_COOKIES.

    ..I can't seem to figure this one out. Please help.
    Last edited by Leith Ross; 04-22-2013 at 07:43 PM. Reason: Added Code Tags

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1