Skip to Content
Jan 20, 2014 at 08:50 AM

How to export SAPUI5 form to Excel ?



In my Project I have created one form to display all data regarding Employee.

The Sample structure of Form is like below.

Now my problem is when click on button I want to export this form into Excel Form.

To get the something like this I used below code.'data:application/,' + encodeURIComponent($('#dvData').html()));

I am getting Excel sheet but not in that format.

In my Excel I got two problems.

  • 1. The width of cells increased based on the data in that cell.(I am not getting the width on that Form)
  • 2. In that form we have two tables.
    • One is having 6 columns
    • Second one is having 7 columns

How to get these Two tables with in Same width ?

How to get the External css also to get the Form like that?

I am getting columns with same width from top to bottom.But in my Form It is totally different. Is it possible to get the Excel sheet like that?

Please help me .



Form.jpg (41.0 kB)