The module I am developing is designed the way that all our features (employee list, employee profile birthday list, telephone list, job list, job profile, request name card form, preview name card, etc.) are in one module in different Asp:View elements and depending on the module settings the selected view is being displayed. Now this causes the following problem:
When the print button of the module is clicked, the print version of the Asp:View which is selected in the module settings is displayed, although a user already might have navigated to another view by some links. E.g. a user starts at the name card request form because in the module settings it is selected to display this Asp:View. When he submitted his name card request, another Asp:View for showing his name card preview will be set to visible. When he now wants to print his sample name card, the window with the print view will show the name card request from instead of the Asp:View where he navigated to.
I guess it is because in the page_load event I am retrieving the view to display from the module settings so the print function will always use that view to display being printed although I might already be on another view where a user usually will get with links and GET parameters. The print button is a JavaScript function and does obviously not include the GET paramters which are currently part of the URL but only the module tab/page so always the default view from the module settings is loaded. So how can we correct this?
Is it furthermore possible to define the area of the module to be displayed for printing? E.g. in the name card preview example, on the name card sample should be displayed, while some other information (date of request, status of workflow etc.) can be skipped.