+ Reply to Thread
Results 1 to 9 of 9

Conditional Format drop-down box

  1. #1
    Registered User
    Join Date
    07-30-2010
    Location
    london
    MS-Off Ver
    Excel 2003
    Posts
    69

    Conditional Format drop-down box

    Hi,

    I have a drop down box in word 2010 with the options "YES", "NO" and "N/A". I want to have conditional formatting for different color & font depending which is chose. e.g:

    Yes = green
    No = bold & red
    N/A = gray

    is there a way to do this?

    Thanks in advance.
    Last edited by omarq; 01-30-2012 at 07:45 AM.

  2. #2
    Forum Expert macropod's Avatar
    Join Date
    12-22-2011
    Location
    Canberra, Australia
    MS-Off Ver
    Word, Excel & Powerpoint 2003 & 2010
    Posts
    3,726

    Re: Conditional Format drop-down box

    Hi omarq,

    You could do that via an 'on exit' macro attached to the formfield and coded as:
    Please Login or Register  to view this content.
    where 'Dropdown1' is the formfield's internal bookmark name.
    Last edited by macropod; 01-31-2012 at 06:23 AM. Reason: Corrected code for Dropdown with 3 options
    Cheers,
    Paul Edstein
    [Fmr MS MVP - Word]

  3. #3
    Registered User
    Join Date
    07-30-2010
    Location
    london
    MS-Off Ver
    Excel 2003
    Posts
    69

    Re: Conditional Format drop-down box

    Thanks. I can't seem to get that working. Nothing seems to happen when i click and exit the form...

  4. #4
    Forum Expert macropod's Avatar
    Join Date
    12-22-2011
    Location
    Canberra, Australia
    MS-Off Ver
    Word, Excel & Powerpoint 2003 & 2010
    Posts
    3,726

    Re: Conditional Format drop-down box

    Is this for a dropdown formfield, or something else? If not for a dropdown formfield, then what?

  5. #5
    Registered User
    Join Date
    07-30-2010
    Location
    london
    MS-Off Ver
    Excel 2003
    Posts
    69

    Re: Conditional Format drop-down box

    Ahh.. yes, sorry i was using a combobox. is it possible to do with that in word 2010?

    thanks

  6. #6
    Forum Expert macropod's Avatar
    Join Date
    12-22-2011
    Location
    Canberra, Australia
    MS-Off Ver
    Word, Excel & Powerpoint 2003 & 2010
    Posts
    3,726

    Re: Conditional Format drop-down box

    You can't apply different colors to your different combobox entries - they must all be the same color. Document content can be any color.

  7. #7
    Registered User
    Join Date
    08-23-2012
    Location
    us
    MS-Off Ver
    Excel 2003
    Posts
    17

    Re: Conditional Format drop-down box

    I need a similar help
    Please see the code below.. the dropdown is unable to refresh with the change in list..basically it stays in the first choice "green" font for all selection. Also instead of font color change, i need to include the background color change accordingly. Any help is appreciated
    Please Login or Register  to view this content.
    Last edited by arlu1201; 08-23-2012 at 03:13 AM.

  8. #8
    Forum Contributor arlu1201's Avatar
    Join Date
    09-09-2011
    Location
    Bangalore, India
    MS-Off Ver
    Excel 2003 & 2007
    Posts
    19,166

    Re: Conditional Format drop-down box

    Wmurugan,

    Welcome to the Forum, unfortunately:

    Your post does not comply with Rule 2 of our Forum RULES. Don't post a question in the thread of another member -- start your own thread. If you feel it's particularly relevant, provide a link to the other thread. It makes sense to have a new thread for your question because a thread with numerous replies can be off putting & difficult to pick out relevant replies.

    Also,

    I have added code tags to your post. As per forum rule 3, you need to use them whenever you put any code in your post. Please add them in future. If you need more information on how to use them, check my signature.
    If I have helped, Don't forget to add to my reputation (click on the star below the post)
    Don't forget to mark threads as "Solved" (Thread Tools->Mark thread as Solved)
    Use code tags when posting your VBA code: [code] Your code here [/code]

  9. #9
    Registered User
    Join Date
    10-24-2012
    Location
    CA, USA
    MS-Off Ver
    Excel 2010
    Posts
    1

    Re: Conditional Format drop-down box

    Quote Originally Posted by omarq View Post
    Hi,

    I have a drop down box in word 2010 with the options "YES", "NO" and "N/A". I want to have conditional formatting for different color & font depending which is chose. e.g:

    Yes = green
    No = bold & red
    N/A = gray

    is there a way to do this?

    Thanks in advance.
    The answer I believe is (assuming you've enabled the Developer Tab) click on the drop down box (any of them, or the 1 you want to change) , click on the Developer tab, click on [U]Properties, when the box opens, be sure to check the box Use style to format contents, then the New Style box will come alive and click on that, then click on the down arrow next to Automatic and select your color.
    You might also want to change the font style too?
    Good luck

+ 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