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 / May 2007

Tip: Looking for answers? Try searching our database.

Link excel table inside a condition

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Alex St-Pierre - 11 May 2007 16:16 GMT
Hi !
I use a mailmerge to produce 1, 2, or 3 graphics for each line of record. I
have an excel file that contains 1 graphic per sheet. The name of the sheet
is store inside {MERGEFIELD1}. After the merge, the path of each graphic must
stay variable to be able to update the document for each graphic (ctrl-A +
F9).
When I do this, all link stay in text after after the merge (work fine)
{ LINK Excel.Sheet8 "\\\\pathpath\\file.xls" "{ MERGEFIELD1 }" \a \p }
When I put the same thing inside a condition, the link MERGEFIELD1 disapear
inside the merged file.
{ IF A=B "No Graphic" "Graphic below:
{ LINK Excel.Sheet8 "\\\\pathpath\\file.xls" "{ MERGEFIELD1 }" \a \p } "}
So, I only see the table result. Since there is no link, all tables are
identical for each record (cannot update it) Is the a way to stay the link
variable when the table link is used inside a condition ?
Thanks!
Alex
Signature

Alex St-Pierre

Peter Jamieson - 11 May 2007 17:31 GMT
Your best bet is probably to have a blank 1-pixel graphic (let's say it is
in sheet "blank" and do something like

{ IF A = B "No Graphic" "Graphic below
" }{ LINK Excel.Sheet8 "\\\\pathpath\\file.xls" "{ MERGEFIELD sheet }" \a
\p }

if the sheet column contains "blank" when you want the blank graphic, or

{ IF A = B "{ SET mysheet "blank" }No Graphic" "{ SET mysheet "{ MERGEFIELD
sheet }" }Graphic below
" }{ LINK Excel.Sheet8 "\\\\pathpath\\file.xls" "{ MERGEFIELD sheet }" \a
\p }

if the sheet column doesn't contain anything you can rely on.

I don't know if that will work but it is what I would try.

Peter Jamieson

> Hi !
> I use a mailmerge to produce 1, 2, or 3 graphics for each line of record.
[quoted text clipped - 17 lines]
> Thanks!
> Alex
Alex St-Pierre - 11 May 2007 18:19 GMT
Hi Peter,
I'm wondering if there's a way to make a merge with a macro and update the
link before each record?
Thanks!
Alex
Signature

Alex St-Pierre

> Your best bet is probably to have a blank 1-pixel graphic (let's say it is
> in sheet "blank" and do something like
[quoted text clipped - 37 lines]
> > Thanks!
> > Alex
Peter Jamieson - 11 May 2007 19:46 GMT
You can use VBA and Word's MailMerge events to modify the Mail Merge Main
Document before each record is merged (MailMergeBeforeRecordMerge event).

The Word VBA has some info. on how to use events if you haven't done that
before, and you might find Doug Robbins' Addin on Graham Mayor's site at
http://www.gmayor.com/individual_merge_letters.htm useful as an example.

Peter Jamieson

> Hi Peter,
> I'm wondering if there's a way to make a merge with a macro and update the
[quoted text clipped - 50 lines]
>> > Thanks!
>> > Alex
 
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.