A way to export files in excel

1. Set the table header, and specify the data range of the table in the table header area (write the function by annotation, and specify it by the function)

2. Set the replacement data in the first row of the table, indicating the key value of the map, the traversal object of the list, such as xxx in xxx.a, xxx.b And specify the data of the last column in the column.

3. Through the tool class, read the above table template data, and then use map-> list to fill in the data. The advantage of this is that the header and format, etc., can be achieved by pre-setting. No need to control the header and style of the code by yourself.

Published 331 original articles · 51 praises · 440,000 visits +

Guess you like

Origin blog.csdn.net/y41992910/article/details/103464860