+ Reply to Thread
Results 1 to 6 of 6

Searching For A Value In A column and then adding data to another column...

  1. #1
    Registered User
    Join Date
    07-08-2008
    Location
    NJ
    Posts
    8

    Searching For A Value In A column and then adding data to another column...

    Okay, here is what I need to do. I want excel to search through the values in column A, and if it locates a value that I specify, (say 145) to add specified text to column B.

    So I want it to filter through a column and then add data into another column if it finds it. So If it finds the 145 in column A, I want it to add the text "Chrome" to column B.

    Can someone help? Can it do this?

  2. #2
    Forum Contributor VBA Noob's Avatar
    Join Date
    04-25-2006
    Location
    London, England
    MS-Off Ver
    xl03 & xl 07(Jan 09)
    Posts
    11,988
    Does this help

    =IF(A1=145,"Chrome","")
    Place in B1 and drag down

    VBA Noob
    _________________________________________


    Credo Elvem ipsum etian vivere
    _________________________________________
    A message for cross posters

    Please remember to wrap code.

    Forum Rules

    Please add to your signature if you found this link helpful. Excel links !!!

  3. #3
    Registered User
    Join Date
    07-08-2008
    Location
    NJ
    Posts
    8

    Almost

    Here are some numbers from Column A

    0000433.008
    0000433.068
    0000441.008
    0000442.295
    0000443.008
    0000443.068
    0000443.299
    0000451.297
    0000452.299
    0000453.008
    0000453.068
    0000453.297
    0000453.299
    0000541.008

    I want this to look and for whichever ones end in .008 lets say, write Chrome next to it in the adjacent cell...basically just focus on the last three characters.

    Thanks!

  4. #4
    Forum Contributor VBA Noob's Avatar
    Join Date
    04-25-2006
    Location
    London, England
    MS-Off Ver
    xl03 & xl 07(Jan 09)
    Posts
    11,988
    Try

    =IF(RIGHT(A1,4)=".008","Chrome","")
    VBA Noob

  5. #5
    Registered User
    Join Date
    07-08-2008
    Location
    NJ
    Posts
    8
    Okay! That worked, but now I am wondering how I can run two formulas on the same column. In column B now, "Chrome" appears wherever there is a ".008" in column A. Now how can I make it ALSO look for ".295" and write "Satin" in B?

  6. #6
    Forum Contributor VBA Noob's Avatar
    Join Date
    04-25-2006
    Location
    London, England
    MS-Off Ver
    xl03 & xl 07(Jan 09)
    Posts
    11,988
    Maybe

    =IF(RIGHT(A1,4)=".008","Chrome",IF(RIGHT(A1,4)=".295","Satin",""))
    VBA Noob

+ 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