Sorry, I do not understand what you are trying to do.
{ if {MERGEFIELD Version} = "CustomerA" "contact abc[ at ]gmai.com"}
should return "contact abc[ at ]gmai.com" IF the Version field contains "CustomerA" AND you used Ctrl+F9 to insert the field delimiters { }
-- 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
"Sunil Sudhakaran" <SunilSudhakaran[ at ]discussions.microsoft.com> wrote in message news:A3439FE0-6870-4B1D-8B7E-73EDBA73019F[ at ]microsoft.com...
[Quoted Text] >I have a Document that is having many Field codes. > > I would like to extract the following information from the if field. > > { if {MERGEFIELD Version} = "CustomerA" "contact abc[ at ]gmai.com"} > > I tried using MailMergeField.Next.Code got the Condition, not able to get > other values > > Dim doc As Document > Dim fld As MailMergeField > Set doc = ActiveDocument > For Each fld In doc.MailMerge.Fields > ........ > If fld.Type = wdFieldIf Then > .......... > MsgBox fld.Next.Code > End if > > How to get the values for Comparison,CompareTo and TrueAutoText > > Regards > Sunil S.
|