+ Reply to Thread
Results 1 to 4 of 4

conditional comments

  1. #1
    Forum Contributor
    Join Date
    03-02-2010
    Location
    Denver, CO
    MS-Off Ver
    Excel 2010
    Posts
    109

    conditional comments

    I am currently working on a file where a numbered grade is given to an assignment, to signify how far along they are. There are certain conditions that would have to be met to acheive a grade. For example, a 1 would mean that no conditions have been met, a 5 would mean that all conditions have been met.

    I'm trying to figure out a way so that the comment box would display only the conditions that have to be met for that grade to be valid. So, if they put in a 1, the comment box would show "No conditions met" or if they put in a 5, the comment box would say "This has happened, this has happened, and this has happened." But it will only show the appropriate comment.

    I imagine that it would be an "if/then" type of macro code, but I have no idea what code would be used to create a comment box, or change or delete it so that it shows the correct comment if they change the number. Also, I've never been able to get a "change event" macro to work with drop down boxes in excel, so that's another problem.

    Any help is greatly appreciated.
    Last edited by just_some_guy; 07-07-2010 at 03:22 PM.

  2. #2
    Forum Expert
    Join Date
    01-12-2007
    Location
    New Jersey
    Posts
    2,127

    Re: conditional comments

    This is a bit of code that should work with a data validation dropdown box. Do note, it is a bit rudimentary, so modify it to suit. If you have any additional questions, please post them with necessary details.

    Please Login or Register  to view this content.

  3. #3
    Forum Contributor
    Join Date
    03-02-2010
    Location
    Denver, CO
    MS-Off Ver
    Excel 2010
    Posts
    109

    Re: conditional comments

    BigBas

    Thanks very much for posting that. I haven't had a chance to test this out today yet, but I did have a question.

    Can this be applied so it works over numerous cells, or do I need to do this for each cell that will need to be effected? This will have a cell for each week, over a period of 52 weeks. It would start in cell D11 and run through BC11. Each of those cells needs to have this work for it. There are about 30 items total that will have these 52 week rows.

    Thanks again for your help!

  4. #4
    Forum Contributor
    Join Date
    03-02-2010
    Location
    Denver, CO
    MS-Off Ver
    Excel 2010
    Posts
    109

    Re: conditional comments

    BigBas,

    Had a chance to try out the macro, and it does what I need it to do with one exception. How do I get it to run any time the cell changes? I've never been able to get a change event to work when using a drop down menu.

    And then also, how do I get it to apply to a range of cells, so that I don't have to re-write this macro for a hundred or so cells? When I tried using set rng=target, it came up with an error. I changed target to selection, and it worked fine. So long as I was only focused on one cell.

    Thanks for the 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