+ Reply to Thread
Results 1 to 16 of 16

Change cell color in vlookup function

  1. #1
    Registered User
    Join Date
    12-04-2012
    Location
    Singapore
    MS-Off Ver
    Excel 2013
    Posts
    66

    Change cell color in vlookup function

    Hi, Sir, I am quite new in excel,

    I have used vlookup function to identify whether the input is correct or not.

    If the input is wrong, i want sell display message is wrong and change color to red,

    how can i change sell color??

    thank you so much

  2. #2
    Forum Guru :) Sixthsense :)'s Avatar
    Join Date
    01-01-2012
    Location
    India>Tamilnadu>Chennai
    MS-Off Ver
    2003 To 2010
    Posts
    12,770

    Re: Change cell color in vlookup function

    Use conditional formatting to change the cell colour.

    In conditional formatting formula use your vlookup formula in the below way...
    Formula: copy to clipboard
    Please Login or Register  to view this content.


    If your problem is solved, then please mark the thread as SOLVED>>Above your first post>>Thread Tools>>
    Mark your thread as Solved


    If the suggestion helps you, then Click *below to Add Reputation

  3. #3
    Registered User
    Join Date
    12-04-2012
    Location
    Singapore
    MS-Off Ver
    Excel 2013
    Posts
    66

    Re: Change cell color in vlookup function

    Hi, sir, thanks a lot. now I got a new question.
    to prevent duplicate entries in my excel sheet, i used data validation to to set COUNTIF($A$1:$A$14,A1)=1
    but I need to entry same number twice now, how should I just type this entry twice and remian other engry still unique?
    Thank you so much for your kindly help

  4. #4
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,929

    Re: Change cell color in vlookup function

    Adam, I have closed your other thread related to your 2nd question (duplicate post)

    the 1st thought that comes to mind is to remove DV from that specific cell?
    1. Use code tags for VBA. [code] Your Code [/code] (or use the # button)
    2. If your question is resolved, mark it SOLVED using the thread tools
    3. Click on the star if you think someone helped you

    Regards
    Ford

  5. #5
    Registered User
    Join Date
    12-04-2012
    Location
    Singapore
    MS-Off Ver
    Excel 2013
    Posts
    66

    Re: Change cell color in vlookup function

    my range cell is from A1toA14, what is DV BTW?

  6. #6
    Forum Guru :) Sixthsense :)'s Avatar
    Join Date
    01-01-2012
    Location
    India>Tamilnadu>Chennai
    MS-Off Ver
    2003 To 2010
    Posts
    12,770

    Re: Change cell color in vlookup function

    Formula: copy to clipboard
    Please Login or Register  to view this content.

  7. #7
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,929

    Re: Change cell color in vlookup function

    Quote Originally Posted by Adamlearnexcel View Post
    Hi, sir, thanks a lot. now I got a new question.
    to prevent duplicate entries in my excel sheet, i used data validation to to set COUNTIF($A$1:$A$14,A1)=1
    but I need to entry same number twice now, how should I just type this entry twice and remian other engry still unique?
    Thank you so much for your kindly help
    DV = data validation

  8. #8
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,929

    Re: Change cell color in vlookup function

    duplicate post

  9. #9
    Registered User
    Join Date
    12-04-2012
    Location
    Singapore
    MS-Off Ver
    Excel 2013
    Posts
    66

    Re: Change cell color in vlookup function

    thank you sir, I just want to enter one number twice. other number still cannot enter twice, how should I do this?
    Thank you so much for your help

  10. #10
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,929

    Re: Change cell color in vlookup function

    like i suggested earlier, if this is just a once (or twice) off thing, then just remove the data validation from those specific cells

  11. #11
    Registered User
    Join Date
    12-04-2012
    Location
    Singapore
    MS-Off Ver
    Excel 2013
    Posts
    66

    Re: Change cell color in vlookup function

    OK,Thank you so much, I know what you mean. however, the data is randomly key into excel sheet, I dont know when the repeat number will be key in, so how should I do? If I just remove from specific cell, people may not key the repeat number into that specific cell, they will random key into other cell

  12. #12
    Forum Guru :) Sixthsense :)'s Avatar
    Join Date
    01-01-2012
    Location
    India>Tamilnadu>Chennai
    MS-Off Ver
    2003 To 2010
    Posts
    12,770

    Re: Change cell color in vlookup function

    Use the below one in your Validation Custom Formula
    Formula: copy to clipboard
    Please Login or Register  to view this content.


    Change the 55 to the Number to which you would like to allow the entry for twice.

  13. #13
    Registered User
    Join Date
    12-04-2012
    Location
    Singapore
    MS-Off Ver
    Excel 2013
    Posts
    66

    Re: Change cell color in vlookup function

    Sir, my A1 is 3BDH000382R0001, it's a product part number, how come when I put in, I can key in this number twice, but cannot key in other number for even once?

  14. #14
    Forum Guru :) Sixthsense :)'s Avatar
    Join Date
    01-01-2012
    Location
    India>Tamilnadu>Chennai
    MS-Off Ver
    2003 To 2010
    Posts
    12,770

    Re: Change cell color in vlookup function

    Its working fine for me. The formula refers to A1 as active cell so apply the formula in Validation by keeping the A1 as active cell.

    Formula: copy to clipboard
    Please Login or Register  to view this content.

  15. #15
    Registered User
    Join Date
    12-04-2012
    Location
    Singapore
    MS-Off Ver
    Excel 2013
    Posts
    66

    Re: Change cell color in vlookup function

    Sir, it works~!!!!Thank you so much for your kindly help.
    I am sure I will have more questions in the future.
    Thank you once again for your patience~!!!

  16. #16
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,929

    Re: Change cell color in vlookup function

    Based on your last post it seems that you are satisfied with the solution(s) you've received but you haven't marked your thread as SOLVED. If your problem has not been solved you can use Thread Tools (located above your first post) and choose "Mark this thread as unsolved".
    Thanks.

    Also, as a relatively new member of the forum, you may not be aware that you can thank those who have helped you by clicking the small star icon located in the lower left corner of the post in which the help was given. By doing so you can add to the reputation(s) of those who helped.

+ 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