Right now I am working on a Xpage which displays data from a domino document. Based on the form of the document different fields will be displayed. Now I want to create a "New" function. My idea here is to set the view I am previously using in edit mode. Additionally, I want to add a radio button which enables a user to choose the form of the document he wants to create. Based on this radio button the document form should change which should result in the elements displayed on the page changing too. Overall if I switch between the radio button options and hit save, a new document will be created with the right form. Yet my problem is that my elements in my view won't change dynamically. So if I switch my form there will still be elements/controls displayed for the default option but not the selected form. My idea was to create an onChange-event for my Radio Button Group. My questions here would be: How can I change my formValue for the Xpage (new document) and then reload it with the new set value?
Thanks for your explanation.
I understand you have one XPage suitable for multiple forms, I assume using a Switch control and custom controls per form. About the New button, you could try first to have 3 New buttons, each for a separate form, and you create a URL like yoursite.com/xpage.xsp?action=newdocument&form=someform
When the user clicks the button, your page can read the parameters (param.action and param.form) and act accordingly. Or do you intend to update the current page using partial refresh, as a single page approach?