Hello!
I have an interactive grid with a date column PSRN. On selection change I have a dynamic action
"const region = apex.region("IG_PS");
const gridView = region.widget().interactiveGrid("getViews", "grid");
const selected = gridView.getSelectedRecords();
if (!selected.length) {
return;
}
const rawDate = selected[0][13];
if (!rawDate) {
return;
}
const [day, month, year] = rawDate.split(".");
if (!day || !month || !year) {
return;
}
const formattedDate = `${day.padStart(2, "0")}.${month.padStart(2, "0")}.${year}`;
$s("P4_PSRN", formattedDate);
apex.server.process("StoreToSessionState", {
pageItems: "#P4_PSRN"
}, {
dataType: "text",
});"
And an ajax callback process with just “Null;”. I've tried many other ways but nothing seemed to work for some odd reason. Even this doesn't work as I'd want it to. When I select a row I can see in session state that the value is what it should be, but when I press the button to pass the value, it doesn't work UNLESS I refresh the page first. I want to know if the problem lies with this set up, or how my button is set up - redirect to page in the same application.
Thanks for any help!