#1
|
|||
|
|||
Drop-down governing text and color of cell in table
Hi community
I am still a beginner with VBA and my goal is to have a dropdown that sets the text and color of the respective cell in a table: - The user selects the red "level" and the requirements are populated based on it (low/med/high) - Ideally, the cells or background of the low/med/high are also color-coded (this is where I struggle) - See the screenshot for visualization I managed to get the low/med/high texts updated based on the level input through CustomXMLNode, but I am currently still struggling with the coloring. The coloring seems inaccessible through the XMLNode...any ideas and also feedback on the code are greatly appreciated, thx! PS: I am using BeforeStoreUpdate instead of OnExit because I want to have it more interactive/quicker given that there is no OnChange Event. PPS: I am using content controls over form fields because a) more modern and b) more responsive at the cost of having to use macros. Do you agree with that? PPPS: Linking to this for awareness. Last edited by tico22; 07-31-2022 at 03:04 AM. Reason: more info |
#2
|
||||
|
||||
Cross-posted at: events - VBA: Changing content control through truly dynamic drop-down - Stack Overflow
For cross-posting etiquette, please read: A message to forum cross posters - Excelguru
__________________
Cheers, Paul Edstein [Fmr MS MVP - Word] |
#3
|
|||
|
|||
Feel free to close here => should have asked directly on StackOverflow
|
Tags |
vba content control |
Thread Tools | |
Display Modes | |
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Drop down list change color of a table cell? | templeowls | Word | 3 | 05-18-2022 02:59 PM |
Drop down fields in Word - Change color of cell, then add text | BernaDev202 | Word VBA | 3 | 08-09-2018 02:29 PM |
Macro to change an RGB table cell shading color to another RGB color | David Matthews | Word VBA | 4 | 05-29-2018 02:45 PM |
How to change the font color of specific text within a Word table cell | epid011 | Word Tables | 2 | 05-15-2017 05:21 PM |
VBA Table – Search All Tables - Find & Replace Text in Table Cell With Specific Background Color | jc491 | Word VBA | 8 | 09-30-2015 06:10 AM |