There isn't a direct way to exclude the sub-items when printing invoices in QuickBooks Desktop (QBDT). However, you can create or build an assembly to exclude the sub-items on the printed invoices. I'm here to help guide you how.
Go to the List menu.
Select on Item List.
Choose Item at the bottom of the list and click on New.
From the Type drop-down menu, select Inventory Assembly. If Inventory Assembly isn't on the list, you need to turn on inventory tracking in preferences
Sign in to your QuickBooks company file as admin.
Go to the Edit menu and select Preferences.
On the left pane, choose Items & Inventory then go to the Company Preferences tab.
Put a check mark on the Inventory and purchase orders are active box.
Enter the name of the assembly that will distinguish the item from any others on the list under the Item Name/Number section.
Go to the Bill of Materials section and add the sub-item from there.
Fill in the required information, click on OK.
Once completed, you can now create an invoice and select the assembly created. The sub-items or items on the assembly won't show up on the Invoice screen, just the (whole) assembly itself.