Thanks so much for your assistance. I very much appreciate it. I followed your directions, pasted the code into the footer and made the adjustments you stated. Sadly, it didn't produce the expected results. The background color didn't change. No color appeared. Here's the modified code in the footer:
<script>
document.addEventListener('DataPageReady', applyColorHandler);
function applyColorHandler() {
let conditionField = document.querySelector("#EditRecordEMR_Color_Ind]");
let virtualField = document.querySelector("div[data-cb-cell-name*='cbParamVirtual2']").nextElementSibling;
if(conditionField.value == 1){
virtualField.style.backgroundColor = '#FF0000';
}
else if(conditionField.value == 2){
virtualField.style.backgroundColor = '#FFFF00';
}
else if(conditionField.value == 3){
virtualField.style.backgroundColor = '#008000';
}
};
</script>
Note the virtual field name was changed to "2" as that was the field that was used. I replaced the colors with hex#s. I confirmed that data in the EMR_Color_Ind field was being produced, and it was. Wondering if I failed to do something. Again, really appreciate your effort. Any thoughts would be valued.
Thanks.
Dale Wilson