VLF-ONE Framework - Download iSeries Table to Excel

This Q&A forum allows users to post and respond to "How Do I Do ....." questions. Please do not use to report (suspected) errors - you must use your regional help desk for this. The information contained in this forum has not been validated by LANSA and, as such, LANSA cannot guarantee the accuracy of the information.
Post Reply
alphabeta13
Posts: 21
Joined: Tue Jan 14, 2020 12:18 am

VLF-ONE Framework - Download iSeries Table to Excel

Post by alphabeta13 »

Hi,

I have a requirement to download records that meet certain criteria from an iSeries table to excel when user clicks on a push button, without showing the records in an instance list.

Any idea on how to do this? I'm using VLF-ONE framework.

Thanks,
Taufik
MarkD
Posts: 692
Joined: Wed Dec 02, 2015 9:56 am

Re: VLF-ONE Framework - Download iSeries Table to Excel

Post by MarkD »

There's several ways to do this.
(1) - Create a CSV file on server and return that file as the payload of your server module.
(2) - Create a CSV stream on the client from data returned by server module in a working list.
(3) - Create a real XLS file using LANSA Integrator.

Note: MS-Excel tends to open CSV formatted files easily.

Some resources / examples are:

For option (2) execute shipped demo framework and search for 'CSV' ...........
Capture_1.PNG
Capture_1.PNG (24.73 KiB) Viewed 8982 times
For option (1) execute shipped demo framework and search for 'download' ...........
Capture_2.PNG
Capture_2.PNG (23.51 KiB) Viewed 8982 times
Last edited by MarkD on Sat May 30, 2020 10:53 am, edited 1 time in total.
MarkD
Posts: 692
Joined: Wed Dec 02, 2015 9:56 am

Re: VLF-ONE Framework - Download iSeries Table to Excel

Post by MarkD »

A quick way to create a CSV file on the server is to use the TRANSFORM_LIST built-in function - use the "AU" or "OU" option.

https://docs.lansa.com/14/en/lansa015/i ... m_list.htm

Also, this is all just Visual LANSA stuff and nothing specific to VLF-ONE.
i.e. VLF-ONE is just a Visual LANSA application
Post Reply