I tried your solution Andrea :
- just one modal window :
modalWindow = new ModalWindowE4N("modalQuestionnaire", "");
questionnaireContentPanel = new
QuestionnaireContentPanel(modalWindow.getContentId(), this);
modalWindow.setContent(questionnaireContentPanel);
modalWindow.setInitialWidth(800);
add(modalWindow);
- after submit, substitute window content with ModuleContentPanel :
membreCourant =
serviceMembre.enregistrerReponses(membreCourant, questionnaireCourant);
SessionE4N.get().setMembre(membreCourant);
//qPage.getModalWindow().close(target);
ModuleContentPanel moduleContentPanel = new
ModuleContentPanel(qPage.getModalWindow().getContentId());
moduleContentPanel.initialiserModule(questionnaireCourant);
qPage.getModalWindow().setTitle("Module
"+questionnaireCourant.getTitre());
qPage.getModalWindow().setContent(moduleContentPanel);
target.addComponent(qPage.getModalWindow());
//qPage.getModalWindow().show(target);
but modal window is not re-render, so it content is not changed...
maybe target.addComponent() is not sufficient?
so I tried also with qPage.getModalWindow().close before changes and
qPage.getModalWindow().show() after changes (with or without
target.addComponent) : in these cases, we can see modal window change a
second and then render with first content...
what am I doing wrong?