Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / Word / Mailmerge and Fax / July 2005

Tip: Looking for answers? Try searching our database.

Embedding quote marks in If-Else-Then statements

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
EHPorter - 28 Jul 2005 19:05 GMT
Is it possible to embed quote marks in If-Else-Then statements?  Some sort
of switch or character that tells the merge to treat the quote mark ( " ) as
part of the text, rather than as part of the If command.

An example.  The line:

{IF {Mergefield "Nicknames"} <> "" "The nickname is "Crash" Johnson" "There
is no nickname"} does not work, because the quotes around the word Crash are
treated as control characters in the If statement.   Is there any way around
this?

Thanks
Doug Robbins - 28 Jul 2005 20:11 GMT
Use the following construction:

{IF {Mergefield "Nicknames"} <> "" { Quote "The nickname is '"'Crash'"'
Johnson" } "There is no nickname"}

where the quote marks either side of Crash are enclosed by apostrophes.
That is

apostrophe double quote apostrophe Crash apostrophe double quote apostrophe

Signature

Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP

> Is it possible to embed quote marks in If-Else-Then statements?  Some sort
> of switch or character that tells the merge to treat the quote mark ( " )
[quoted text clipped - 8 lines]
>
> Thanks
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.