DesiLogi Posted February 16, 2018 Report Share Posted February 16, 2018 Hello, I have some code running in the footer of an Update datapage that on change of one virtual field (Virtual 4: drop down) gets the value of another virtual field (Virtual 7: cascading text, with Virtual 4 as the ParentID) and copies that value of Virtual 7 into a text64000 field. The problem is it keeps getting the 'previous' value of Virtual 7 and not the current one, when Virtual 4 is updated. Meaning the code runs the 'copy' function BEFORE Virtual 7 is updated. I need to get the 'updated' data from Virtual 7 and copy that into the text64000 field. The code I'm using is: $("[name='cbParamVirtual4']").change(function(){ f_copy_print_address('cbParamVirtual7', 'cke_EditRecordShipToAddress'); }); So if there's some way to 'refresh' or 'update' Virtual 7 before the f_copy_print_address code runs that'd be great. Many thanks! Quote Link to comment Share on other sites More sharing options...
douvega Posted March 14, 2018 Report Share Posted March 14, 2018 Have you tried to fire the script when the cascading element changes? $("[name='cbParamVirtual7']").change(function(){ f_copy_print_address('cbParamVirtual7', 'cke_EditRecordShipToAddress'); }); Quote Link to comment Share on other sites More sharing options...
DesiLogi Posted March 26, 2018 Author Report Share Posted March 26, 2018 Hi Douvega, Thanks for the tip- I had tried firing the script on the change for the element and still had the same issue. I ended up changing the overall process and datapage for what I was doing and got a solution that way. 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.