On export, don't include hidden subfields? [RESOLVED]

When exporting form entries, is it possible to automatically not include hidden sub-fields in fields such as Name and Address?

Here’s what I’m dealing with:
Client has a large group of people divided into a few dozen smaller groups. Each small group gets a couple always-active forms for various things, and the forms always include Name and Address fields that each have hidden sub-fields. For example, the Name fields always have First and Last active, but Prefix, Middle and Suffix are always hidden. When exporting, those hidden fields create columns in the spreadsheet that have header text, but are otherwise empty.

I know that those sub-fields can be de-selected on the Export page, but this takes a lot of time when there are dozens of forms to export (the client always wants all the forms’ entries at the same time, multiple times per year).

What I’m hoping for is a way to somehow automatically not include columns for hidden sub-fields in the exported csv file. This would save a ton of time and effort for my client, as well as me. Is that possible?

You can do this using the gform_export_fields filter. See the following page of the documentation for the code:

1 Like

Thanks so much!! I had searched the documentation but missed that one.

1 Like