Excel Export at runtime

0
Hello Experts I have 10 columns and at run time I want to select any 5 columns and then generate excel file for those columns only Just wanted your view if it is possible to do so? If yes then how? Thank you
asked
2 answers
1

Read the documentation here about customizations: https://docs.mendix.com/howto/integration/using-the-excel-exporter

After this, you know it’s possible. Then you need for example to show a checkbox list with column names (model reflection) and you need to pass those data to a microflow via associated object. In this microflow, fill the document template with the selected column names. This is just an idea, not tested.

answered
1

Hi,

I believe that’s can be done by using Excel -Exporter module :

1- first read the documentation for the excel-exporter.

2-Create one template that’s include all the 10 columns 

3- on your list you can retrieve the template by the name ,And by using non Persistable entities get sheets and the columns and insert them there with an check box to choose the columns you want

Note : Don’t forget to link the template you retrieve with the header non-per entity to retrieve it at the next step

4- appear them at a popup and let the user choose the columns he wants to appear at the excel 

5- after that run a MF to create a new template with the new columns. and link the data with that template

Note : To duplicate the data, You can use community commons Java actions (Clone,Deep Clone),To make it simpler to create the template.

6- then download  the new template 

7- after the download delete the new template that you create .

that’s like a hints for you to implement ,Hope that will be useful for you .

 

answered