Excel Fromating #chat


Asim
 

Hi All,

I'm in the process of generating a price list directly to excel, I was wondering if anyone has had any experience in formatting the cells in a excel sheet from Unipaas 1.9p.

The current approach is populating a vector with all the field values and then dumping them out line row by row. However, each row may contain a mixture of number, dates and text. The current thought i have is to create a an identical vector but purely for formatting. But i'm not sure how i would go back over the excel sheet to apply the formatting. Has anyone had any experience with a similar task? and suggestions for a alternative would also be great.

Any help would be appreciated. 

Thanks, 
Asim  


Andreas Sedlmeier
 

Hi Asim,

Depends a bit on how complex the final excel sheets will be, if you do this from within Magic with .NET however (and thats one way to go) you will end up with a huge amount of .NET stuff which is hard to maintain, to debug and to test.

Relatively easy it would be if you create .NET or Java code (f.i. from a Magic merge template), compile it, and run it. Thats exactly what MSE does when you create a RIA client for Windows Mobile or Android with the Interface builder.

When you decide for Java (good choice): There's Apache POI which allows you to create office documents (all versions), without being required to have Office actually installed. It also ships with plenty of examples:
https://poi.apache.org/components/spreadsheet/quick-guide.html

Thats the alternative I would suggest :). In the file section there's MS Office code which you could use as well. Most of it is very old, and wont work anymore ... I fear.

Best regards,

Andreas


Wes Hein
 

Asim,

There is OfficeCom or Office Magic projects in the files section, I know the OfficeCom does this very easily.

Wes


Heidi Schuppenhauer
 

Office Magic still works and it's open source. But, you do need to have Excel installed for it to work.

Heidi.Schuppenhauer

 

 


On Wed, Jan 23, 2019 at 9:37 AM Wes Hein <wes@...> wrote:
Asim,

There is OfficeCom or Office Magic projects in the files section, I know the OfficeCom does this very easily.

Wes