+ Reply to Thread
Results 1 to 4 of 4

Dynamic highlighting of portions of rows based on a category

  1. #1
    Registered User
    Join Date
    05-17-2012
    Location
    Washington, DC
    MS-Off Ver
    Excel 2010
    Posts
    2

    Dynamic highlighting of portions of rows based on a category

    Hello everyone.

    The problem: I have a spreadsheet with stocks listed on them, with the following columns:
    Ticker, Name, Shares, Price, Value, Day Gain/Loss, Hold Gain/Loss, YTD Gain/Loss

    I wish to create a series of buttons that will represent a category of stock, i.e. bank stocks. The result of pressing this button would be to highlight in some color the rows in which the bank stocks are located, but only through to the last used column (i.e. not the entire row). The idea being I could assign each stock a category (bank, consumer, industrial, etc.) and be able to highlight those that match this category with the click of a mouse button. There would also be one to reset to nothing being highlighted, but I assume this should be fairly easy after dealing with the main issue.

    Anyone have any ideas/tips/suggestions of how I could start making this a reality?
    Thanks!
    Attached Files Attached Files

  2. #2
    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,938

    Re: Dynamic highlighting of portions of rows based on a category

    this isnt exactly using buttons, but it uses a drop-down data validation list and conditional formatting. i made a start, see if its something you could work with?

    You didnt give the criteria for your colors, so i just started the CF to match the 1st letter of the stock list with the 1st letter in the pull-down
    Attached Files Attached Files
    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

  3. #3
    Registered User
    Join Date
    05-17-2012
    Location
    Washington, DC
    MS-Off Ver
    Excel 2010
    Posts
    2

    Re: Dynamic highlighting of portions of rows based on a category

    Thanks man, this is exactly what I was looking for. In fact it is better than my proposed button solution. Mark this one solved!

  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,938

    Re: Dynamic highlighting of portions of rows based on a category

    glad to help

+ 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