94
Views
3
Comments
Solved
How to export Excel without hidden columns in Data Grid Web
Application Type
Traditional Web
Service Studio Version
11.53.7 (Build 60881)
Platform Version
11.16.0 (Build 36096)

Hi everyone 

Forge of Data Grid Web is used in the program. 

If I hide a few items on the screen, and then click the Excel Download Button, the items are exported in the Excel even though they are hidden. How can I export the Excel without these items ?

For Example:

I have hidden items 1, 2, 3 and 4.

When I click the Excel Export Button, the excel will be exported like this:

I don't want to export with items 1,2,3,4.


Any suggestion is appreciated.

Kind Regards

2024-07-02 12-36-01
Constança Branco
Solution

Hi YITONG LYU,

You can achieve this by including the following code on the advanced properties of the export button:

"  includeColumns: function(column) {     return  column.visible;  }"


Hope it helps


2024-12-24 00-58-47
YITONG LYU

@Constança Branco 

Deeply appreciated. 

I tried it on the program. 

This exactly solves my problem.

Thanks a lot.

UserImage.jpg
Harsh Sharma

Hi @Constança Branco ,

I have a similar case where I want to include the hidden columns as well while exporting CSV in data grid web. 

I tried to understand the solution provided here but did not get where to apply this as in the export to excel button I cannot see any advance properties section.

How can I achieve this. Thanks in advance.

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