Handling wide form combobox list entries

I’ve been having an issue where the combobox in a form is not wide enough for the list to show the full text of the options. I couldn’t find a way to make the list wider “out of the box” so came up with this solution and thought I’d share it. This assumes there are no popups on the screen.

var Combo = Form.getItem("combo").getWidget();
Combo.events.on("afterOpen", function() { 
dhx.awaitRedraw().then(function(){ 
var el = document.getElementsByClassName('dhx_popup-content')[0]; 
el.style.width = '400px'; }) 
});
1 Like