Group Fields in Mail merge based on common field

Sinon

Active Member
Joined
Aug 6, 2015
Messages
298
Hi there! I have a task at work that requires the use of mail merge letters (these are to be printed in the end not sent via email).


Basically, we have a database of companies that are grouped in their own categories (column B - "Group" in the spreadsheet), each purchasing a product valued at one of two costs. Cost 1 refers to payments before a certain date and Cost 2 refers to later payments. In the letters, we are trying to show the clients (Column C - "Client Name) how much they would have to pay before and after the date (the date is 1st April but is irrelevant here as the prices have already been set in the spreadsheet). Furthermore, if the clients decide to buy multiple products, they get a discounted total price (column E - "Reduced Cost 1" and column G - "Reduced Cost 2"), also based on when they make the payment. In my table, I chose to put the discounted total price for all the lines but I really only need it for a total number.


What I am trying to achieve is to be able to save and print individual letters per group. I've tried adapting some code I found online but I can't make it work. To make it worse, we absolutely have to use a table in word to show all the clients and the prices. this only confuses me further as I could find no code to help with setting up the data in a table in Word the way I need it. i have attached the spreadsheet with some sample data (i have over 90 groups) and also how the document looks before the mail merge and how I would like it to look like in the end.

I've attached the files in question here: https://www.dropbox.com/sh/pg591ijrk8argzs/AABX2l1ipLGorX01oScD6hSza?dl=0


I wouldn't mind having to change the spreadsheet to get it into a better format for the mail merge, it doesn't have to have this current format. My requirements are to get 1 letter per group and keep in the table in Word.
Any help would be greatly appreciated. Thanks


FYI: I've tried the following links:
https://www.youtube.com/watch?v=bld2UWKdTmo
https://www.youtube.com/watch?v=4Ck8KAwAQso
Word: Use Directory Grouping Features in Letter Mail Merge ~ Stacy DuBois' Tech Blog
I've also posted on Excelforum.com
 

Excel Facts

Format cells as currency
Select range and press Ctrl+Shift+4 to format cells as currency. (Shift 4 is the $ sign).

Forum statistics

Threads
1,223,302
Messages
6,171,299
Members
452,396
Latest member
ajl_ahmed

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top