I have unboud form frmMain that has unboud subform frmSubMain. Form frmSubMain has as data source a query.
Sub form frmSubMain is in datasheet view .
When the form frmSubMain is populated user first see all columns on form and he can export values from the form to excel by exporting underlying form query . That works well and no problem.
However user has option to hide some columns and show just particular columns based on set of check boxes that user select (each check box fires a procedure that hide some columns on the form)
I want to export this query to excel but just visible columns of that form after user make selection and click on export button.
I need something to pull out visible fields from form underlying query I assume it should be done through form record set clone.
Option to create a new query with visible fields and export is not good as user has so many options- combinations which fields to see which fields to hide. So option with exporting just those selected visible fields(columns) would be solution.
Any idea how to export form underlying query but not all fields of query just those that are visible on this form.