Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.word.mailmerge.fields
|
|||
|
|||
![]()
Hi,
This is a pressing issue. I got as far as connecting to the database and creating the record lines. In the last step, however, I can only select 'merge into a new document'. The result of this is a simple list of all records on one page. I then have to manually have to add header, footer, logo etc. However we do this a lot... Can I create a template that will be used for the final document? Can I use database fields in this template? I know it must be possible because we have a demo template, that automatically opens a document with a dummy logo, some more information and presents a list of the merged rows. However I cannot see anywhere where I can EDIT or MODIFY this template. If anyone has a clue how to achieve this please let me know... both how to create a new template and edit/modify the example one I have... Thanks for your help! |
#2
![]()
Posted to microsoft.public.word.mailmerge.fields
|
|||
|
|||
![]()
In the last step, however, I can only select
'merge into a new document'. Yes, this is the only option for directory merges. However we do this a lot... Can I create a template that will be used for the final document? Can I use database fields in this template? You can do this, but a. it is not trivial to include headings that are only displayed at the beginning of the merge (or at the top of each page). b. in my view, it is inadvisable to connect the template to the data source, unless the data source is fully multi-user, e.g. a SQL Server database. I know it must be possible because we have a demo template, that automatically opens a document with a dummy logo, some more information and presents a list of the merged rows. However I cannot see anywhere where I can EDIT or MODIFY this template. A template can either be a. a real Word template (.dot file), in which case you would typically create a new Mail merge document using File|New and selecting the template you want from the dialog. Word creates a copy of the template as a .doc file and leaves the original untouched. b. a Word document (.doc file), in which case you (or your users) have to be a bit more careful not to overwrite the original document. To edit a template (.dot), you first have to locate it. Templates can be in various places - look in Word Tools|Options|but for example mine are in C:\Documents and Settings\my windows login name\Application Data\Microsoft\Templates - you would need to substitute your own login name to create the correct path. To edit a template, use File|Open to navigate to the correct folder and open the .dot file. You may need to change the settings in Windows Explorer|Tools|FolderOptions|View to do that. Earlier I said: You can do this, but a. it is not trivial to include headings that are only displayed at the beginning of the merge (or at the top of each page). b. in my view, it is inadvisable to connect the template to the data source, unless the data source is fully multi-user, e.g. a SQL Server database. The reason for (a) is that all the fields and text you put in the mail merge main document are repeated for /every/ record in the data source. If for example, your directory has a single row table, then to have headings, you need a heading row n the table. But this is repeated for every record, and there is no way to make it only appear above the first record. If you do not use a table, you can use an IF field to insert fields and text that will only appear above the first record, but in recent versions of Word, this sometimes seems to cause problems. You can also put headings into the document header and they will of course be repeated for each page. The alternative is to add them after the merge, and a fairly easy way to do that is to keep the headings you need in a separate file and use File|Insert to insert it. The reason for (b) is that in recent versions of Word, when you create a mail merge main document based on a template that has a data source attached, Word tries to open the data source again when it creates the document based on the template. It cannot always do that because of locking issues. A possible workaround is not to have the template connected to a data source, and to use a VBA AutoNew macro to set up the data source. Peter Jamieson "Ido" wrote in message ... Hi, This is a pressing issue. I got as far as connecting to the database and creating the record lines. In the last step, however, I can only select 'merge into a new document'. The result of this is a simple list of all records on one page. I then have to manually have to add header, footer, logo etc. However we do this a lot... Can I create a template that will be used for the final document? Can I use database fields in this template? I know it must be possible because we have a demo template, that automatically opens a document with a dummy logo, some more information and presents a list of the merged rows. However I cannot see anywhere where I can EDIT or MODIFY this template. If anyone has a clue how to achieve this please let me know... both how to create a new template and edit/modify the example one I have... Thanks for your help! |
#3
![]()
Posted to microsoft.public.word.mailmerge.fields
|
|||
|
|||
![]()
Hi Peter,
Let me give you a bit more background... We are using Microsoft Dynamics CRM 3.0 on an SQL database that is accessible for those users that need to use this template. So there won't be database locking issues. In CRM, we have an entity called quote. A quote contains a header (one record) and can have multiple so-called 'line-items' (lines about each product that is added to the quote; each line item corresponds to a different record). Now I am using a demo template, which behaves as follows. I call the Print Quote function from within CRM; this opens the Word dialog box where I choose the Quote template. Then all the records are displayed and I click OK. I can (and have) modified this template to look slightly different and include some more information about the line item. In any case, so far everything seems to be normal. Then, when I do the final merging step (by selecting Merge Into a New Document), here's the strange thing: instead of just giving a simple list of the rows from the previous steps (each row corresponding to a line item), it also ADDS a logo, and information from the HEADER record, i.e. specific info about this quote. Now I do not assume you have knowledge of CRM or it's database structure, but that's irrelevant. Assume database connections are working properly. How do I track where the 'second' template (the one with the logo) is selected from? I checked the template for Macros, ToolsMacroMacros but there are none. So how come it just pops up? * I have looked everywhere for a .dot file that resembles this one, but I cannot find it. In fact, In order to use this template I simple copied and pasted this particular file Quote.dot into my /Templates .... So it seems to do all this stand-alone Thanks, Ido "Peter Jamieson" wrote: In the last step, however, I can only select 'merge into a new document'. Yes, this is the only option for directory merges. However we do this a lot... Can I create a template that will be used for the final document? Can I use database fields in this template? You can do this, but a. it is not trivial to include headings that are only displayed at the beginning of the merge (or at the top of each page). b. in my view, it is inadvisable to connect the template to the data source, unless the data source is fully multi-user, e.g. a SQL Server database. I know it must be possible because we have a demo template, that automatically opens a document with a dummy logo, some more information and presents a list of the merged rows. However I cannot see anywhere where I can EDIT or MODIFY this template. A template can either be a. a real Word template (.dot file), in which case you would typically create a new Mail merge document using File|New and selecting the template you want from the dialog. Word creates a copy of the template as a .doc file and leaves the original untouched. b. a Word document (.doc file), in which case you (or your users) have to be a bit more careful not to overwrite the original document. To edit a template (.dot), you first have to locate it. Templates can be in various places - look in Word Tools|Options|but for example mine are in C:\Documents and Settings\my windows login name\Application Data\Microsoft\Templates - you would need to substitute your own login name to create the correct path. To edit a template, use File|Open to navigate to the correct folder and open the .dot file. You may need to change the settings in Windows Explorer|Tools|FolderOptions|View to do that. Earlier I said: You can do this, but a. it is not trivial to include headings that are only displayed at the beginning of the merge (or at the top of each page). b. in my view, it is inadvisable to connect the template to the data source, unless the data source is fully multi-user, e.g. a SQL Server database. The reason for (a) is that all the fields and text you put in the mail merge main document are repeated for /every/ record in the data source. If for example, your directory has a single row table, then to have headings, you need a heading row n the table. But this is repeated for every record, and there is no way to make it only appear above the first record. If you do not use a table, you can use an IF field to insert fields and text that will only appear above the first record, but in recent versions of Word, this sometimes seems to cause problems. You can also put headings into the document header and they will of course be repeated for each page. The alternative is to add them after the merge, and a fairly easy way to do that is to keep the headings you need in a separate file and use File|Insert to insert it. The reason for (b) is that in recent versions of Word, when you create a mail merge main document based on a template that has a data source attached, Word tries to open the data source again when it creates the document based on the template. It cannot always do that because of locking issues. A possible workaround is not to have the template connected to a data source, and to use a VBA AutoNew macro to set up the data source. Peter Jamieson "Ido" wrote in message ... Hi, This is a pressing issue. I got as far as connecting to the database and creating the record lines. In the last step, however, I can only select 'merge into a new document'. The result of this is a simple list of all records on one page. I then have to manually have to add header, footer, logo etc. However we do this a lot... Can I create a template that will be used for the final document? Can I use database fields in this template? I know it must be possible because we have a demo template, that automatically opens a document with a dummy logo, some more information and presents a list of the merged rows. However I cannot see anywhere where I can EDIT or MODIFY this template. If anyone has a clue how to achieve this please let me know... both how to create a new template and edit/modify the example one I have... Thanks for your help! |
#4
![]()
Posted to microsoft.public.word.mailmerge.fields
|
|||
|
|||
![]()
You are correct that I don't have Dynamics here. My guess is that its
templates are using the Word object's MailMerge Events to include material for each record merged (and perhaps at the end of the merge. If they have written that stuff in VBA, you may be able to find the code that does it in the template you edited. However, they could have used an add-in, or written the code in a .NET language, and the code is not necessarily available to you. Not particulalry easy to discover which of those things they have done, but if you can find a suitable Dynamics group, someone may know the answer. Peter Jamieson "Ido" wrote in message ... Hi Peter, Let me give you a bit more background... We are using Microsoft Dynamics CRM 3.0 on an SQL database that is accessible for those users that need to use this template. So there won't be database locking issues. In CRM, we have an entity called quote. A quote contains a header (one record) and can have multiple so-called 'line-items' (lines about each product that is added to the quote; each line item corresponds to a different record). Now I am using a demo template, which behaves as follows. I call the Print Quote function from within CRM; this opens the Word dialog box where I choose the Quote template. Then all the records are displayed and I click OK. I can (and have) modified this template to look slightly different and include some more information about the line item. In any case, so far everything seems to be normal. Then, when I do the final merging step (by selecting Merge Into a New Document), here's the strange thing: instead of just giving a simple list of the rows from the previous steps (each row corresponding to a line item), it also ADDS a logo, and information from the HEADER record, i.e. specific info about this quote. Now I do not assume you have knowledge of CRM or it's database structure, but that's irrelevant. Assume database connections are working properly. How do I track where the 'second' template (the one with the logo) is selected from? I checked the template for Macros, ToolsMacroMacros but there are none. So how come it just pops up? * I have looked everywhere for a .dot file that resembles this one, but I cannot find it. In fact, In order to use this template I simple copied and pasted this particular file Quote.dot into my /Templates .... So it seems to do all this stand-alone Thanks, Ido "Peter Jamieson" wrote: In the last step, however, I can only select 'merge into a new document'. Yes, this is the only option for directory merges. However we do this a lot... Can I create a template that will be used for the final document? Can I use database fields in this template? You can do this, but a. it is not trivial to include headings that are only displayed at the beginning of the merge (or at the top of each page). b. in my view, it is inadvisable to connect the template to the data source, unless the data source is fully multi-user, e.g. a SQL Server database. I know it must be possible because we have a demo template, that automatically opens a document with a dummy logo, some more information and presents a list of the merged rows. However I cannot see anywhere where I can EDIT or MODIFY this template. A template can either be a. a real Word template (.dot file), in which case you would typically create a new Mail merge document using File|New and selecting the template you want from the dialog. Word creates a copy of the template as a .doc file and leaves the original untouched. b. a Word document (.doc file), in which case you (or your users) have to be a bit more careful not to overwrite the original document. To edit a template (.dot), you first have to locate it. Templates can be in various places - look in Word Tools|Options|but for example mine are in C:\Documents and Settings\my windows login name\Application Data\Microsoft\Templates - you would need to substitute your own login name to create the correct path. To edit a template, use File|Open to navigate to the correct folder and open the .dot file. You may need to change the settings in Windows Explorer|Tools|FolderOptions|View to do that. Earlier I said: You can do this, but a. it is not trivial to include headings that are only displayed at the beginning of the merge (or at the top of each page). b. in my view, it is inadvisable to connect the template to the data source, unless the data source is fully multi-user, e.g. a SQL Server database. The reason for (a) is that all the fields and text you put in the mail merge main document are repeated for /every/ record in the data source. If for example, your directory has a single row table, then to have headings, you need a heading row n the table. But this is repeated for every record, and there is no way to make it only appear above the first record. If you do not use a table, you can use an IF field to insert fields and text that will only appear above the first record, but in recent versions of Word, this sometimes seems to cause problems. You can also put headings into the document header and they will of course be repeated for each page. The alternative is to add them after the merge, and a fairly easy way to do that is to keep the headings you need in a separate file and use File|Insert to insert it. The reason for (b) is that in recent versions of Word, when you create a mail merge main document based on a template that has a data source attached, Word tries to open the data source again when it creates the document based on the template. It cannot always do that because of locking issues. A possible workaround is not to have the template connected to a data source, and to use a VBA AutoNew macro to set up the data source. Peter Jamieson "Ido" wrote in message ... Hi, This is a pressing issue. I got as far as connecting to the database and creating the record lines. In the last step, however, I can only select 'merge into a new document'. The result of this is a simple list of all records on one page. I then have to manually have to add header, footer, logo etc. However we do this a lot... Can I create a template that will be used for the final document? Can I use database fields in this template? I know it must be possible because we have a demo template, that automatically opens a document with a dummy logo, some more information and presents a list of the merged rows. However I cannot see anywhere where I can EDIT or MODIFY this template. If anyone has a clue how to achieve this please let me know... both how to create a new template and edit/modify the example one I have... Thanks for your help! |
Reply |
Thread Tools | |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
NO CODE - mail merge to Outlook with attachment with CC | Mailmerge | |||
Editing Mail Merge Recipients | Mailmerge | |||
No print option in Step 6 of Directory mail merge | Mailmerge | |||
protect mail merge record template so others may 'save as' & use | Tables | |||
How can I create an index for a directory created from mail merge? | Mailmerge |