Solved

Mail merge, suppression of entire paragraphs

Posted on 2015-02-02
11
80 Views
Last Modified: 2015-12-06
I am doing a merge into a Word document of data from an Excel spreadsheet. My merged Word document is formatted as a number list (say 12 numbered sections, each of which contains fields from  the spreadsheet). I have no problems with doing this, but I want, as and when I require it, to suppress some of those numbered sections entirely. What happens at the moment, quite correctly, is that I produce a Word document with all the required fields putting the correct data into my Word doc., and all is well. However, I want, quite frequently, to only show say sections 1,3,5,6,7 and 9 on my Word doc. Although these sections will all have their fields correctly filled in from the spreadsheet, I don't want to show them in my Word doc.
Hope that's clear. So I feel I am now a dab hand at doing the fields, but I have no idea of how to automatically, and on my command (somehow) suppress these sections when I want to in Word, or even if it's possible. Is it possible, and if so, how? Oh, and maybe also renumber these paragraphs after suppressing the bits I don't want, so that the numbering is then, again, continuous, rather than having missing numbers 2,4 and 8.
Many thanks,
Regards.
0
Comment
Question by:BlosMusic
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 6
  • 5
11 Comments
 
LVL 12

Expert Comment

by:FarWest
ID: 40583767
could you upload a sample files for word and spreadsheet,
I think part of the solution is to modify the way things are organized in the document
0
 

Author Comment

by:BlosMusic
ID: 40583923
Can this be done without the documents being on general public view?
0
 
LVL 12

Expert Comment

by:FarWest
ID: 40584115
please check your messages
0
Save the day with this special offer from ATEN!

Save 30% on the CV211 using promo code EXPERTS30 now through April 30th. The ATEN CV211 connects a laptop directly to any server allowing you instant access to perform data maintenance and local operations, for quick troubleshooting, updating, service and repair.

 

Author Comment

by:BlosMusic
ID: 40584144
I've done this. Not sure if it went, but anyway, if you don't get something let me know.
Many thanks.
Regards,
0
 
LVL 12

Expert Comment

by:FarWest
ID: 40584179
got it, I will look at the files now
0
 
LVL 12

Expert Comment

by:FarWest
ID: 40584297
hi, do you consider price,payment terms, supply as sections so you want for example to hide payment terms section?

BTW I think you only use mail merge for first record is this correct?(not for all 7 that includes in example, is this correct?
0
 

Author Comment

by:BlosMusic
ID: 40584362
No, typically I only want to suppress paragraphs 3-7, or some of those. I will almost always have paragraphs 1 and 2. And, no, I shall always want the payment terms and prices. But again, I might want to suppress some of the price items (e.g. local control panel, instrumentation, etc.).
As regards your second comment about  using mail merge only for the first record: no, I use them in all the paragraphs (wherever you see the «field» signs, of course).
The summary is that I just want to be able to suppress any of the actual paragraphs 1 to 7 (it's unfinished, so there will be more) at will. I know that the merge fields will still be there, but I want to stop the document displaying the numbered paragraphs I don't want. You will realize that I am trying to make an all-singing merge document that will enable my staff to generate an accurate quotation based on a complex set of data, as quickly as possible. Sometimes there will not be 'fans', sometimes no 'pipes' . . . . and so on.
0
 
LVL 12

Accepted Solution

by:
FarWest earned 500 total points
ID: 40584459
so you mean by section a mail merge document output?
if general I tried this code use ctrl-F9 and type between brackets , of course you can store values in the excel sheet it self and use it as merged field"
{IF { {MERGEFIELD Print_Payment} = 1 "copy and paste all payment text including paragraph number" ""}

and if you keep paragraph numbering auto from word it will renumber based on its visibility

but the best way to get where you want (calculation sheet to produce a word quotation is to make  final tables layout including text paragraph in the excel itself then copy and paste those tables to word as linked table,
and if you want printable Quotation and not word you may consider printing directly from excel
0
 

Author Comment

by:BlosMusic
ID: 40588177
Thanks. I am now looking into how to do this - seems complicated, but the trouble is I know nothing about MERGEFIELDS; so I shall learn about it, try it, and shout again as and when i get into a tangle!
Thanks again.
0
 

Author Comment

by:BlosMusic
ID: 40588976
Well, I've done it quite well, I think. But can you tell me how to remove a blank line when one of the paragraphs is empty?
I have used CONCATENATION to build up a paragraph in Excel, as you recommended, and that all works perfectly. But if this paragraph, which I can suppress now, isn't there, then I end up with an extra, ugly-looking, blank line in the Word document. How can i get rid of this line, so it is only there when the particular paragraph is used?
0
 

Author Closing Comment

by:BlosMusic
ID: 41358371
I never closed this question, but the answer was good!
0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I recently resolved a client's Office 2013 installation problem and wanted to offer an observation that may help you with troubleshooting similar issues. The client ordered three Dell Optiplex system units with the Windows 7 downgrade option inst…
PaperPort has a feature called the "Send To Bar". It provides a convenient, drag-and-drop interface for using other installed software, such as Microsoft Office. However, this article shows that the latest Office 2016 apps (installed with an Office …
This video walks the viewer through the process of creating Hyperlinks for the web and other documents. Select the "Insert" tab: Click "Hyperlink":  Type "http://" followed by a web address to reference a website or navigate to a document to ref…
The view will learn how to download and install SIMTOOLS and FORMLIST into Excel, how to use SIMTOOLS to generate a Monte Carlo simulation of 30 sales calls, and how to calculate the conditional probability based on the results of the Monte Carlo …

710 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question