38
Views
8
Comments
How to create an Excel Generator for all kind of lists?
Application Type
Traditional Web, Mobile, Reactive, Service

Hi,

I want to create a Server Action that can be used anywhere in the application (or in other applications) to generate an Excel file with the data of a passing List.

The thing is that I want this regardless of the type of the List that I pass to the Server Action.

I don't know if I need to do data conversion of the original list to the List I'll need to iterate to write the Excel File.

Somebody knows if it can be done? or it's impossible?

Thanks in advance!

Common_Excel.oml
2024-02-29 15-59-19
Smit

Hello,

I am attaching the post URL that explains the step by step converting your list into Excel data here.
URL: How to Export Entity Data to Excel - OutSystems How to Guide 
Let me know if this resolves your question or not.

Thanks :)

UserImage.jpg
JonasAlvHar

Hi Smit,

Thanks for answering!

This is not the solution I'm searching, because I want to create a custom Excel :(

I've attached my OML with an example of the server action I've created to generate a custom excel and I wanted to do this globally. 

But anyways, thanks for answering!! :)

UserImage.jpg
Milind Bansal

Hi JonasAlvHar,

You can use advance excel forge component.
https://www.outsystems.com/forge/component-overview/355/advanced-excel-o11

Thanks

UserImage.jpg
JonasAlvHar

Hi Milind,

I'm using the extension Advance Excel :)

I've attached my OML with an example of the server action I've created to generate a custom excel and I wanted to do this globally.  

The problem is the type of the List I'm passing at the begining :(

2019-01-07 16-04-16
Siya
 
MVP

The answer is no. OutSystems does not offer a generic List Type for use in applications. However, the `ListRemove` method from the System module accepts an input type of "Generic Record List". While you can attempt to copy this type to your variable and pass it as a generic list type, it will not compile successfully.

UserImage.jpg
JonasAlvHar

Hello Siya,

Sad to read that :(

I'm going to try the Generic Record List and I'll tell any news, let's see if this works!

Thanks for answering!! :)

2023-05-08 05-34-05
Piyali Saha

Hello JonasAlvHar,

If you want to create a simple excel without any formatting and all, then you can use outsystems widget RecordListToExcel which takes list as an input and gives excel in the form of binary data which you can download using download widget. You will get this widget in server action.

Please let me know if you need any help.

Regards,

Piyali Saha

UserImage.jpg
JonasAlvHar

Hi Piyali,

As I said to Smit, this is not the solution I'm looking for, because I want to create a custom Excel :(

I've attached my OML with an example of the server action I've created to generate a custom excel and I wanted to do this globally. 

But anyways, thanks for answering!! :)

Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.