Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 04-24-2023, 01:43 PM
Jbro00 Jbro00 is offline How to get different labels depending on data? Windows 11 How to get different labels depending on data? Office 2021
Novice
How to get different labels depending on data?
 
Join Date: Apr 2023
Posts: 3
Jbro00 is on a distinguished road
Default How to get different labels depending on data?


Hopefully I haven't overlooked something simple here...
I need mail merge to create labels, the information will be pulled from an excel sheet.
Say I'm selling food, I have the customers information and all the different food items they have ordered.
I would like the labels to be
Customer info, food order, food order, food order, next customer info, food order, etc...

My data sheet is basically set up as following
Customer info - item ordered - quantity

If a customer ordered 1 beef burrito, and 2 checken burritos how would I go about making mail merge print,
Customer info, beef burrito, chicken burrito, chicken burrito?

I may not even be in the right ball park here but any advice or guidance is greatly appreciated.
Reply With Quote
  #2  
Old 04-24-2023, 08:28 PM
gmayor's Avatar
gmayor gmayor is offline How to get different labels depending on data? Windows 10 How to get different labels depending on data? Office 2019
Expert
 
Join Date: Aug 2014
Posts: 4,101
gmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud of
Default

If each label takes data from one row of the worksheet, then this is a simple mail merge to labels. If the labels are to contain data from multiple rows, then this would be a many to one merge to labels which Word is not capable of. I don't know of a many to one merge to labels add-in to make this happen.
__________________
Graham Mayor - MS MVP (Word) (2002-2019)
Visit my web site for more programming tips and ready made processes www.gmayor.com
Reply With Quote
  #3  
Old 04-25-2023, 03:15 AM
Jbro00 Jbro00 is offline How to get different labels depending on data? Windows 11 How to get different labels depending on data? Office 2021
Novice
How to get different labels depending on data?
 
Join Date: Apr 2023
Posts: 3
Jbro00 is on a distinguished road
Default

Quote:
Originally Posted by gmayor View Post
If each label takes data from one row of the worksheet, then this is a simple mail merge to labels. If the labels are to contain data from multiple rows, then this would be a many to one merge to labels which Word is not capable of. I don't know of a many to one merge to labels add-in to make this happen.
Currently it's all one row. If there is a separate order placed it creates another row but would act as if it just a different customer, I believe this could probably be fixed in excel to merge them.


I'm having difficulty figuring out how to set up the mail merge. How would I go about getting it to put customer info in a label and then each order in another? Some customers will have one order and some will have 2,3,4 orders etc.
Since the amount of orders can vary would I use some type of if then, rule?
I know I could set the labels up with customer info, insert item 1, item2, item3, etc
But then that would leave me with wasted blank labels for instance when customer only orders 1 item and it would leave off any items after the 3rd.
Hopefully I'm explaining this in a way that makes sense? Thanks for taking your time to respond.
Reply With Quote
  #4  
Old 04-25-2023, 07:48 AM
gmayor's Avatar
gmayor gmayor is offline How to get different labels depending on data? Windows 10 How to get different labels depending on data? Office 2019
Expert
 
Join Date: Aug 2014
Posts: 4,101
gmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud of
Default

Just enter all the relevant fields on the label. If there is no data in the field for a particular record nothing will print on the label.

I there are gaps, then conditionally insert the field e.g.
{ MERGEFIELD CUSTOMER }{IF { MERGEFIELD FIELDNAME1 } <> "" "
{MERGEFIELD FIELDNAME1 }" }{IF { MERGEFIELD FIELDNAME2 } <> "" "
{MERGEFIELD FIELDNAME2 }" }ETC


Mail merge labels with Microsoft Office covers the merge process, although originally written for an earlier Word version, the process remains similar.
__________________
Graham Mayor - MS MVP (Word) (2002-2019)
Visit my web site for more programming tips and ready made processes www.gmayor.com
Reply With Quote
  #5  
Old 04-25-2023, 08:46 AM
Jbro00 Jbro00 is offline How to get different labels depending on data? Windows 11 How to get different labels depending on data? Office 2021
Novice
How to get different labels depending on data?
 
Join Date: Apr 2023
Posts: 3
Jbro00 is on a distinguished road
Default

Quote:
Originally Posted by gmayor View Post
Just enter all the relevant fields on the label. If there is no data in the field for a particular record nothing will print on the label.

I there are gaps, then conditionally insert the field e.g.
{ MERGEFIELD CUSTOMER }{IF { MERGEFIELD FIELDNAME1 } <> "" "
{MERGEFIELD FIELDNAME1 }" }{IF { MERGEFIELD FIELDNAME2 } <> "" "
{MERGEFIELD FIELDNAME2 }" }ETC


Mail merge labels with Microsoft Office covers the merge process, although originally written for an earlier Word version, the process remains similar.
I'm still not quite understanding, I could upload the files I'm currently using for reference if that would help.
If create a table with customer information and rows for orders I can imput that onto the labels to insert customer info, sale1, sale2, sale2, sale4, sale5, next customer info, etc.
When I do it in this fashion if the customer bought two things it leaves me with 3 blank labels when I'm ready to print. This would lead to many wasted labels.
I'm not sure if this is the same way you're explaining to do it?
I really appreciate your time, do you have any recommended places I can look to become more familiar with vba and these types of situations? I feel bad basically asking you to teach me so I can understand the advice that you are giving. I don't mind learning more and getting a better understanding and then coming back to this thread to move further but I'm having a hard time finding a good place to learn the information.
Reply With Quote
  #6  
Old 04-25-2023, 01:11 PM
kilroyscarnival kilroyscarnival is offline How to get different labels depending on data? Windows 10 How to get different labels depending on data? Office 2021
Expert
 
Join Date: May 2019
Posts: 344
kilroyscarnival is just really nicekilroyscarnival is just really nicekilroyscarnival is just really nicekilroyscarnival is just really nice
Default

Wasted labels? What types of labels and what type of printer are you using?

Why Excel? Is this for a restaurant where you will have considerable volume throughout the day, or some more small-scale food business where you have all your orders in advance of printing?

I'm thinking a point-of-sale system of some kind would be better if you are doing any kind of volume.
Reply With Quote
  #7  
Old 04-25-2023, 08:27 PM
gmayor's Avatar
gmayor gmayor is offline How to get different labels depending on data? Windows 10 How to get different labels depending on data? Office 2019
Expert
 
Join Date: Aug 2014
Posts: 4,101
gmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud of
Default

It sounds like you are merging just one record, hence the reference to wasted labels, as mail merge always starts from label 1. Maybe a different approach is called for.

You could consider Envelope or label add-in for Word which doesn't use mail merge but can print one or more labels from an Excel data source. You can select which fields go on the labels and which label to start with.

It takes a bit of effort to configure to your requirements, but then is simple enough for repetition.
__________________
Graham Mayor - MS MVP (Word) (2002-2019)
Visit my web site for more programming tips and ready made processes www.gmayor.com
Reply With Quote
Reply

Thread Tools
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
creating multiple data rows, for labels based on a cell value josbor01 Excel Programming 3 01-02-2018 02:04 PM
How to get different labels depending on data? Populating ranking depending upon ranges of previous cell's data sryder Excel 5 04-07-2016 03:37 PM
Method to remove overlap in data labels for single series omahadivision Excel Programming 0 12-28-2012 08:55 PM
Powerpoint: adding data to trend lines w/o data labels HaiLe PowerPoint 0 04-11-2011 09:21 AM
Show different Data depending on Imput Value Aton Word 0 09-15-2010 03:43 AM

Other Forums: Access Forums

All times are GMT -7. The time now is 01:30 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2024 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft