+ Reply to Thread
Results 1 to 4 of 4

Using IF Search Function in Mail Merge

  1. #1
    Registered User
    Join Date
    05-23-2017
    Location
    London, UK
    MS-Off Ver
    2016
    Posts
    2

    Using IF Search Function in Mail Merge

    Hello, I am new to the the forum so hello to all!

    I was wondering if someone can please help me;

    I have created a mail merge from excel into a word email message and have added an IF function to the merge-field using the "Rules" tab.

    I am using the "IF" function but rather than have it insert the additional text if the merge-field is "equal to" I would like to be able to add the text or for it to "trigger" if the merge-field contains a certain word or phrase.

    This is because I have two different possible insertions depending on the merge field but would like a third option where if the merge-field contains both "chosen words or phrases then it will show both the additional inserted text (without creating a third option)

    i have tried adding "SEARCH" but without success.

    i hope I have explained this clearly and not put anyone to sleep!

    I would really appreciate it some one could help me with this.

    thank you very much in advance.

    Alfred.
    Attached Files Attached Files
    Last edited by Alfred1; 05-23-2017 at 12:29 PM. Reason: Additional Information As Requested

  2. #2
    Banned User!
    Join Date
    02-05-2015
    Location
    San Escobar
    MS-Off Ver
    any on PC except 365
    Posts
    12,168

    Re: Using IF Search Function in Mail Merge

    Attach a sample workbook. Make sure there is just enough data to demonstrate your need. Include a BEFORE sheet and an AFTER sheet in the workbook if needed to show the process you're trying to complete or automate. Make sure your desired results are shown, mock them up manually if necessary.

    Remember to desensitize the data.

    Click on GO ADVANCED and then scroll down to Manage Attachments to open the upload window.

  3. #3
    Registered User
    Join Date
    05-23-2017
    Location
    London, UK
    MS-Off Ver
    2016
    Posts
    2

    Re: Using IF Search Function in Mail Merge

    Hello sandy666

    Thank you for your response, I have added a couple of files as you request, one is the data source and the other the merge template.
    The merge template contains the "merge Field" "FieldA" - the data is what will populate or trigger the "smart fields", (as you can see there are 3 sheets within the data file providing the 3 options).

    the first one (Sheet Option 1) is straight forward, the smart field would add the merge (hidden text) "yes we can do this for you"

    If the data was sent with sheet option 2 as the response the smart field would be populated with the hidden merge text "yes we can do that for you"

    the third sheet option 3 would trigger anything at the moment (which is my problem); what i want it to do is show both hidden text sentences, as shown in the third answer.

    My thought is that instead of using the IF function with "= "Equal to" (as used in options 1 and 2) to use a function which I haven't used before which I think is called either "SEARCH" or "ISNUMBER" and use it in all three examples

    So instead of using "Answer_1" or "Answer_"" we would be saying if it contain "1" anywhere or in option 2 "2" anywhere and then we could have the third option of 1 2 so it would trigger both hidden fields to show as the data contains both 1 & 2

    Thank you for your help again, I am sorry I am not able to perhaps explain it better.

    Thank you

  4. #4
    Banned User!
    Join Date
    02-05-2015
    Location
    San Escobar
    MS-Off Ver
    any on PC except 365
    Posts
    12,168

    Re: Using IF Search Function in Mail Merge

    I think you mixed two things: Word and Excel
    Pay attention on Excel, what you want to do there, show BEFORE and AFTER so we can see what you want to achieve (in Excel)

    If you want Excel reaction on something what will happen in Word you will need VBA and not on this forum (probably)

    I read post #1 and #3 few times and honestly I don't understand what you want to do and how it should be working

    Maybe someone else will understand better and will give you solution.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [SOLVED] Set VBA search function to only search one row and also not show duplicates?
    By TomToms in forum Excel Programming / VBA / Macros
    Replies: 9
    Last Post: 09-05-2014, 04:00 PM
  2. IF(count(search) Function not working when search from text from a cell
    By joshnathan in forum Excel Formulas & Functions
    Replies: 9
    Last Post: 10-09-2013, 05:13 AM
  3. MailMerge
    By turnej in forum Excel General
    Replies: 0
    Last Post: 05-17-2013, 10:20 AM
  4. [SOLVED] Search function to search if worksheet contains specified text
    By mougiasm in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 01-07-2013, 02:50 PM
  5. Replies: 1
    Last Post: 10-18-2012, 05:52 AM
  6. Mailmerge Search & Replace
    By PooH in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 07-21-2010, 06:04 AM
  7. mailmerge
    By frank in forum Excel General
    Replies: 1
    Last Post: 02-24-2005, 04:06 PM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1