Consulting

Results 1 to 2 of 2

Thread: Activesheet Name to Change col_index_number of a vlookup

  1. #1
    VBAX Mentor jammer6_9's Avatar
    Joined
    Apr 2007
    Location
    Saudi Arabia
    Posts
    318
    Location

    Activesheet Name to Change col_index_number of a vlookup

    Is it possible to change a certain formula in a target cell by changing only the sheet name. I am trying to do is when I rename the Tabsheet, it will edit my formula which is cell link. I just want to edit the the formula in range a4.

    =sheet1!$A$4


    [vba]
    Private Sub Worksheet_SelectionChange(ByVal Target As Range)
    sheet1!$A$4 = ActiveSheet.Name 'might be change when sheet is renamed.
    End Sub

    [/vba]

    Sorry, wrong subject entered...
    Last edited by jammer6_9; 03-03-2008 at 06:01 AM.
    T-ogether
    E-veryone
    A-chieves
    M-ore


    One who asks a question is a fool for five minutes; one who does not ask a question remains a fool forever.

  2. #2
    Distinguished Lord of VBAX VBAX Grand Master Bob Phillips's Avatar
    Joined
    Apr 2005
    Posts
    25,453
    Location
    Surely, that already automatically happens when you rename the sheet?
    ____________________________________________
    Nihil simul inventum est et perfectum

    Abusus non tollit usum

    Last night I dreamed of a small consolation enjoyed only by the blind: Nobody knows the trouble I've not seen!
    James Thurber

Posting Permissions

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