Elderberg Posted May 1, 2020 Report Share Posted May 1, 2020 I'm having trouble getting a cascading dropdown to refresh programatically : I have two fields: Field1 (dropdown) and Field2(cascading dropdown), when the page loads I can using javascript set the value of Field1, but the corresponding Field2 does not recalculate. its always stuck filtering off the first item in the Field1 dropdown. Quote Link to comment Share on other sites More sharing options...
Elderberg Posted May 7, 2020 Author Report Share Posted May 7, 2020 I resolved a way to trigger an onchange event on Field1 programmatically. Once the onchange event is triggered the cascading dropdown refreshes properly. var e = document.querySelector("[id*=cbParamVirtual40]"); e.dispatchEvent(new Event('change')); Quote Link to comment Share on other sites More sharing options...
DesiLogi Posted September 7, 2022 Report Share Posted September 7, 2022 Hi @Elderberg, I know this is a couple years too late but thanks for posting this--it's extremely helpful in dealing with cascading dropdowns. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.