Export Table in Excel in separated tab

  • Thread starter Thread starter Bart
  • Start date Start date
B

Bart

Hi I have a table name "Main". In this table, there is a field name "Support
Group" (i.e. A, B,C). I want to export the table "Main" into excel. But I
want this to be in different tab based on the "Support Group" indicated on
record. Therefore, there will be 3 tabs with name A,B and C.

Is this possible?
 
Yes, it is possible, but you will have to do a separate export for each
Support Group.

Instead of the table, use a query you can filter by Support Group.
Then use the Range Argument of the TransferSpreadsheet method to pass the
name of the worksheet you want for that group, but use the same file name for
all groups. VBA Help says the Range Option does not work for exports, but it
really does.
 
It works! Appreciate your help!

Klatuu said:
Yes, it is possible, but you will have to do a separate export for each
Support Group.

Instead of the table, use a query you can filter by Support Group.
Then use the Range Argument of the TransferSpreadsheet method to pass the
name of the worksheet you want for that group, but use the same file name for
all groups. VBA Help says the Range Option does not work for exports, but it
really does.
 
Back
Top