+ Reply to Thread
Results 1 to 2 of 2

Replacement

  1. #1
    Registered User
    Join Date
    04-19-2004
    Posts
    18

    Replacement

    Hi

    I want to replace NameY (fixed) with NameX, but name X change for every sheet. So my intetion is to relate it to the contain in cell J2 that is different at different sheet.

    I have this code now but as I have told you i want to relate it to the contain in cell J2.

    Sub ReplaceName()
    '

    Cells.Replace What:="NameY", Replacement:="NameX", LookAt:=xlPart, _
    SearchOrder:=xlByRows, MatchCase:=False, SearchFormat:=False, _
    ReplaceFormat:=False
    End Sub

    Thanks

    Rune

  2. #2
    slingsh0t@hotmail.com
    Guest

    Re: Replacement

    Try this:
    Replacement:=Range("j2").Value
    ....between your stars, but remove the stars to run the code, of course.


+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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