I am trying to change the template contents of a HtmlBoxLayout component after a screen closes by using the following code:
PatientSubFormBrowse screen = screenBuilders.screen(this)
.withScreenClass(PatientSubFormBrowse.class)
.withLaunchMode(OpenMode.DIALOG)
.withAfterCloseListener(event -> {
htmlBox.setTemplateContents("<b>Hello</b>");
})
.build();
screen.show();
but nothing happens. It is not working.
Is there a bug ? Or am I doing something wrong ?