Skip to main content
Question

I can’t convert JavaScript from the Classic UI to Modern UI TypeScript code.

  • March 7, 2026
  • 0 replies
  • 37 views

mos11
Freshman I
Forum|alt.badge.img
<ClientEvents TabChanging="refreshGrid" />
<px:PXJavaScript runat="server" ID="CstJavaScript23" Script="function refreshGrid(){ var custGridTotal = document.getElementById("ctl00_phG_tab_t6_CstFormView8&quot;); if(custGridTotal != null &amp;&amp; custGridTotal != undefined){ custGridTotal.object.refresh(); console.log(&quot;custGridTotal&quot;); } }" IsStartupScript="True" />

I want to convert my JavaScript code to Modern UI TypeScript code. How can I do it? I cannot find any documentation about it. I found @handleEvent in TypeScript, but it does not have TabChanging or many other events that exist in the JavaScript client-side.