Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 05-21-2015, 05:51 PM
baum12 baum12 is offline Group records - multiple IF stmts - Text After Group Windows 7 64bit Group records - multiple IF stmts - Text After Group Office 2010 64bit
Novice
Group records - multiple IF stmts - Text After Group
 
Join Date: May 2015
Posts: 1
baum12 is on a distinguished road
Default Group records - multiple IF stmts - Text After Group

Attachment 6501Hi,


I am merging Excel and Word - My key field is EMPLID. I get the EMPLID to start the next new EMPLID but what I am not getting is the middle.

My multiple rows are {IF {TYPE}="Journals" {CompleteCitation} ""}
HEADING
{IF {TYPE}="Invited" {CompleteCitation} ""}
add in another HEADING
{IF {TYPE}="Books" {CompleteCitation} ""}

etc.

I have attached a .pdf of what I have. My word document that I am merging is 3 pages long without any merge fields.

Thank you for taking a look and any help will be greatly appreciated.
Attached Files
File Type: pdf Review Template.pdf (73.0 KB, 15 views)
Reply With Quote
  #2  
Old 05-25-2015, 12:57 AM
DougMVP DougMVP is offline Group records - multiple IF stmts - Text After Group Windows 7 32bit Group records - multiple IF stmts - Text After Group Office 2010 32bit
Advanced Beginner
 
Join Date: Nov 2013
Posts: 50
DougMVP will become famous soon enough
Default

I am not sure that you need the { IF { MERGESEQ } = 1 construction as there does not appear to be any data being repeated for the EMPLID.

However for the { IF { MERGEFIELD Type } construction, assuming that there are just the two possible results - "Journals" and "Invited", you should use

{ MERGEFIELD CompleteCitation }¶
{ IF { MERGEFIELD Type } = "Journals" "Peer-reviewed original manuscripts (pre-populated from WUPS Publications) Textbooks, chapters, reviews:" "Other materials (e.g. pamphlets or computer programs) Planned Publications" }

Note: Mail Merge "out-of-the-box" cannot handle a mail merge with legacy FormFields { FORMTEXT }. However, there is a facility to do that on my MergeTools Add-in.

You can download the MergeTools – 20150422.dotm Add-in that I created from the following page of my One Drive:

http://bit.ly/1hduSCB

The MergeTools – 20150309.dotm file needs to be saved in the Word Startup folder. In Windows Vista and Windows 7, 8 or 8.1, the default location for that folder is

C:\Users\[User Name]\AppData\Roaming\Microsoft\Word\STARTUP

If you do not see the AppData folder: -

In Windows 7, - In Windows Explorer, click on the Organize drop down and then on Folder and search options and in the Folder Options dialog, go to the View tab and select the item "Show hidden files, folders, and drives". While there, it is a good idea to uncheck the box of "Hide extensions for known file types".

In Windows 8 and 8.1, in the File Explorer, click on Options on the View tab of the ribbon and then on the View tab in the dialog that appears and select the item "Show hidden files, folders, and drives". While there, it is a good idea to uncheck the box of "Hide extensions for known file types".

When that has been done and Word is started\re-started, a Merge Tools tab will be added to the Ribbon.
On that tab, there is a button for applying protection to the Mail Merge main document and another one for executing the merge.


The requirements for using the system are:
1. The mail merge main document must be of the Letter type, though that does not mean that the output cannot be sent as an e-mail message.
2. For the Many To One, Merge with Attachments and Merge to Individual Docs utilities, the data source may be either a table or query in an Access database, or in the form of an Excel worksheet and that worksheet must be the first sheet in the Excel workbook. If the data is on some other sheet, you can easily move that sheet so that it is the first sheet in the workbook by clicking on the sheet tab and dragging it to the left. For the Chart Merge utility, download the Mail Merging with Charts document that is also on that page of my OneDrive for additional requirements of the data source for use with that utility
3. For a data source in the form of an Excel worksheet, the field names must be in the first row of the worksheet and there must be a field name in all of the cells in that row that are within the range of columns that contain the data.
4. For both types of data source, the field names must contain only alphanumeric characters (No @,#,$,%,&,(,), etc) and the field names must not start with a numeric character (0-9). The number of characters in the field names, including spaces, must not be more than 40.
5. For a data source in the form of an Excel worksheet, the data must start in the second row of the worksheet and there should be no empty rows within the range of data that is to be processed.

NOTE: The MergeTools applications cannot handle “Compound” MergeFields such as the «AddressBlock» or «GreetingLine».Instead of using those fields, you will need to insert the individual merge fields.
You may also want to download:
1. the Merging with Attachments document that is also on that page which explains how the system is used.It is not actually necessary to have separate attachments as the facility can be used to send just the documents created by the merge itself as attachments, either as the body of the message itself or in the form of Word files or .pdf files.


2. the Mail Merging with Charts document that is also on that page.That document explains how you must set up the Excel Data Source and the Mail Merge Main document to be able to execute a merge with a Chart that is unique to each record in the data source.


3. the Using the Many to One Facility document that describes how to use that facility.

The Add-in also includes a utility for creating a Many-to-One type merge for which you would otherwise need to use the


""}
{
SET EMPLID1 { MERGEFIELD EMPLID } }
{IF{EMPLID1} <> {EMPLID2}"

type construction. It would however require the development of a customized version of the Add-in to handle both (FormFields and ManytoOne) of those requirements.
Reply With Quote
Reply

Tags
group, key field, merge



Similar Threads
Thread Thread Starter Forum Replies Last Post
Group records - multiple IF stmts - Text After Group Group Text with Images Jazz43 Word 1 02-09-2015 03:38 PM
Group Table Rows/Column (like Excel Group) eoinymc Word 1 03-11-2014 04:51 AM
Group records - multiple IF stmts - Text After Group Heading line preceding group of records jag_man653 Mail Merge 1 03-19-2013 04:51 PM
How might I group a bunch of text boxes without getting a space around the edge? Augusta PowerPoint 0 08-25-2011 01:42 AM
multiple calendar entries across a group halfhearted Outlook 0 10-11-2009 12:13 PM

Other Forums: Access Forums

All times are GMT -7. The time now is 06:44 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