<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0">
<channel>
<title>Efficy Overflow Q&amp;A - Recent questions tagged word-template</title>
<link>https://overflow.efficy.io/?qa=tag/word-template</link>
<description>Powered by Question2Answer</description>
<item>
<title>Does anyone knows how to access the DOCU_DOCU relation inside a Template?</title>
<link>https://overflow.efficy.io/?qa=6928/does-anyone-knows-access-docudocu-relation-inside-template</link>
<description>&lt;p&gt;&lt;strong&gt;Does anyone knows how to access the DOCU_DOCU relation inside a Template?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;I activated the relation &lt;code&gt;DOCU_DOCU&lt;/code&gt; for a customer, everything is fine in Efficy Interface. &lt;/p&gt;

&lt;p&gt;But I need to get information of &lt;code&gt;DOCU_DOCU&lt;/code&gt; into a template, so I used : &lt;code&gt;[$GetTable('Docu')] ... Word Table ... [/$]&lt;/code&gt;  into my template ... but the table does want to be display in the resulting document and I don't have any errors.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;https://overflow.efficy.io/?qa=blob&amp;amp;qa_blobid=17855570743522508009&quot; alt=&quot;docu_docu_template.png&quot;&gt;&lt;/p&gt;

&lt;p&gt;I have correct data in the Database and when I merge the document I see that the following Query is called and it returns data.&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;select DOCU_DOCU.*, DOCUMENTS.REFERENCE, DOCUMENTS.NAME, DOCUMENTS.OPENED from DOCU_DOCU DOCU_DOCU join DOCUMENTS DOCUMENTS on DOCU_DOCU.K_DOCUMENT2 = DOCUMENTS.K_DOCUMENT
where (DOCU_DOCU.K_DOCUMENT = 227)
order by DOCUMENTS.NAME
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;&lt;img src=&quot;https://overflow.efficy.io/?qa=blob&amp;amp;qa_blobid=7656570290584351299&quot; alt=&quot;DOCU_DOCU_Query_Result.png&quot;&gt;&lt;/p&gt;

&lt;p&gt;Result of the Template&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;https://overflow.efficy.io/?qa=blob&amp;amp;qa_blobid=18154582510439964989&quot; alt=&quot;docu_docu_template_result.png&quot;&gt;&lt;/p&gt;
</description>
<category>Efficy/ Client side</category>
<guid isPermaLink="true">https://overflow.efficy.io/?qa=6928/does-anyone-knows-access-docudocu-relation-inside-template</guid>
<pubDate>Wed, 14 Jun 2023 14:51:46 +0000</pubDate>
</item>
<item>
<title>Cannot access certain field of Product in template</title>
<link>https://overflow.efficy.io/?qa=6879/cannot-access-certain-field-of-product-in-template</link>
<description>&lt;p&gt;Hello,&lt;/p&gt;

&lt;p&gt;I want to generate an Instant Document (using a docx template) of a contact, showing all products of that contact. I am able to show the &lt;code&gt;NAME&lt;/code&gt; field of each product, but not &lt;code&gt;R_FAMILY&lt;/code&gt;. For the latter, I get the following error:&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;Error while executing script &quot;CreateInstantDoc&quot; at line 820 char 3. (File &quot;efficy\serverscripts\Create.js&quot; line 231)
Message: &quot;DS_DocuEdit_6_Docu_Prod: Field 'R_FAMILY' not found (word\document.xml)&quot;
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;To link the products of the contact to the document, I added the following code to the &lt;code&gt;CreateInstantDoc&lt;/code&gt; function in &lt;code&gt;Create.js&lt;/code&gt;:&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;var Cont = Efficy.getMainDetail(DocuContext, ntCont);
if (Cont != 0) {
    Efficy.copyDetails2(DocuContext, ntCont, Cont, [ntComp, ntProj, ntProd], false, false);
    var ContContext = Efficy.openConsultContext(ntCont);
    var QueryHandle = 0;
    var ProdDataSet = Efficy.consultDetail(QueryHandle, ContContext, Cont, ntProd, true, true, 0);
    ProdDataSet.First;
    while (! ProdDataSet.Eof) {
        var K_Product = ProdDataSet.FieldByName('K_PRODUCT').AsFloat;
        Efficy.insertDetail2(DocuContext, ntProd, K_Product, false);
        ProdDataSet.Next;
    }
}
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;In the docx template, I use the following:&lt;br&gt;
&lt;code&gt;[$GetTable('PROD')] &amp;lt;#repeat&amp;gt;&amp;lt;#F=R_FAMILY&amp;gt;&amp;lt;/#repeat&amp;gt;
 [/$]&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;Could you help me with this?&lt;/p&gt;
</description>
<category>WorkFlow / Serverscript</category>
<guid isPermaLink="true">https://overflow.efficy.io/?qa=6879/cannot-access-certain-field-of-product-in-template</guid>
<pubDate>Fri, 14 Apr 2023 10:32:38 +0000</pubDate>
</item>
<item>
<title>Convert number to letter multilingual to display in Template</title>
<link>https://overflow.efficy.io/?qa=6831/convert-number-to-letter-multilingual-to-display-template</link>
<description>&lt;p&gt;Do we have a module to convert number to letter, in order to display the number in letter into a template?&lt;/p&gt;
</description>
<category>Efficy/ Client side</category>
<guid isPermaLink="true">https://overflow.efficy.io/?qa=6831/convert-number-to-letter-multilingual-to-display-template</guid>
<pubDate>Fri, 03 Mar 2023 15:20:22 +0000</pubDate>
</item>
<item>
<title>Custom filename after launch template</title>
<link>https://overflow.efficy.io/?qa=6286/custom-filename-after-launch-template</link>
<description>&lt;p&gt;How can I manipulate filename after launching a template?&lt;br&gt;
For example I want to have the reference as prefix in my filename&lt;/p&gt;
</description>
<category>Efficy/ Client side</category>
<guid isPermaLink="true">https://overflow.efficy.io/?qa=6286/custom-filename-after-launch-template</guid>
<pubDate>Tue, 14 Sep 2021 08:19:51 +0000</pubDate>
</item>
<item>
<title>Template with generateProposal function</title>
<link>https://overflow.efficy.io/?qa=6023/template-with-generateproposal-function</link>
<description>&lt;p&gt;Hello,&lt;/p&gt;

&lt;p&gt;When I use the generate Proposal function to generate a template with linked products, the font of the getTable ('Prod') block is automatically in Arial while the rest of the document has another font.&lt;/p&gt;

&lt;p&gt;Is it possible in the options of the function to define the font?&lt;/p&gt;
</description>
<category>Efficy/ Client side</category>
<guid isPermaLink="true">https://overflow.efficy.io/?qa=6023/template-with-generateproposal-function</guid>
<pubDate>Thu, 08 Apr 2021 12:44:36 +0000</pubDate>
</item>
<item>
<title>Can I use a virtual field as a template merge field? (usage= p)</title>
<link>https://overflow.efficy.io/?qa=5532/can-i-use-a-virtual-field-as-a-template-merge-field-usage-p</link>
<description>&lt;p&gt;Can I use a virtual field as a template merge field? &lt;br&gt;
SYS_FIELDS: (usage= p)&lt;/p&gt;

&lt;p&gt;Currently I get empty results when merged results.&lt;/p&gt;

&lt;p&gt;For example: &lt;/p&gt;

&lt;pre&gt;&lt;code&gt;[$=PROJ.V_PRODUCTVALUE_Y1] or [$=PROJ.V_TOTALVALUE_Y1, FORMAT=&quot;,0.00&quot;]
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;Et cetera.&lt;/p&gt;
</description>
<category>Efficy/ Client side</category>
<guid isPermaLink="true">https://overflow.efficy.io/?qa=5532/can-i-use-a-virtual-field-as-a-template-merge-field-usage-p</guid>
<pubDate>Mon, 03 Aug 2020 09:27:58 +0000</pubDate>
</item>
<item>
<title>Can i use [$GetTable] filter param to get specific results? (Document Tempalte)</title>
<link>https://overflow.efficy.io/?qa=5338/gettable-filter-param-specific-results-document-tempalte</link>
<description>&lt;p&gt;Hello,&lt;/p&gt;

&lt;p&gt;Context : &lt;strong&gt;Docx template&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;I want to get the list of linked actions to a publication.&lt;/p&gt;

&lt;p&gt;The specific is that i need to get only the actions that has a specific type.&lt;/p&gt;

&lt;p&gt;Could i use the param '&lt;strong&gt;filter&lt;/strong&gt; ' of the &lt;strong&gt;[$GetTable('ACTI')]&lt;/strong&gt; function to get this result? and how?&lt;/p&gt;

&lt;p&gt;Or do have another solution?&lt;/p&gt;

&lt;p&gt;Thanks&lt;/p&gt;

&lt;p&gt;Regards,&lt;br&gt;
Akram &lt;/p&gt;
</description>
<category>WorkFlow / Serverscript</category>
<guid isPermaLink="true">https://overflow.efficy.io/?qa=5338/gettable-filter-param-specific-results-document-tempalte</guid>
<pubDate>Mon, 02 Mar 2020 11:33:54 +0000</pubDate>
</item>
<item>
<title>launch template from Publ or Prof Consult! Efficy 11.2</title>
<link>https://overflow.efficy.io/?qa=4876/launch-template-from-publ-or-prof-consult-efficy-11-2</link>
<description>&lt;p&gt;Hello,&lt;/p&gt;

&lt;p&gt;I want to launch a template threw a &lt;strong&gt;consult commande&lt;/strong&gt; From &lt;strong&gt;Publications Consult&lt;/strong&gt; page, i've created this function to take the directly the &lt;strong&gt;template key in parameters&lt;/strong&gt;:&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;const launchTemplateFromConsult = (template) =&amp;gt; {
var extraParam = format('template=$0&amp;amp;Key={key}&amp;amp;{entity}= 
                {key}&amp;amp;copydetail={entity};{key};Comp;Cont,Proj;Oppo', template);
EditNewWithScript2('Docu', extraParam, 'serverscripts/Create', 
                'CreateInstantDoc');
};
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;My problem is that when the document is created the copy detail function does not work properly like &lt;strong&gt;(contacts or companies are not copied)&lt;/strong&gt;, i don't know if there is some thing missing&lt;/p&gt;

&lt;p&gt;I've also add this 2 lines in the Create.js in the &lt;strong&gt;CreateInstantDoc&lt;/strong&gt; function to copy the details that i need,&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;var Publ = Efficy.getMainDetail(DocuContext, ntPubl)
Efficy.copyDetails2(DocuContext, ntPubl, Publ, [ntComp, ntCont, ntProj, ntOppo], false, false)
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;but the function steel not working.&lt;/p&gt;

&lt;p&gt;Could you help me please?&lt;/p&gt;

&lt;p&gt;Thanks&lt;/p&gt;
</description>
<category>Efficy/ Client side</category>
<guid isPermaLink="true">https://overflow.efficy.io/?qa=4876/launch-template-from-publ-or-prof-consult-efficy-11-2</guid>
<pubDate>Wed, 09 Oct 2019 09:25:57 +0000</pubDate>
</item>
<item>
<title>Word Template did not fill fields from relation table of a new created entity</title>
<link>https://overflow.efficy.io/?qa=4826/word-template-fill-fields-from-relation-table-created-entity</link>
<description>&lt;p&gt;Hi all,&lt;/p&gt;

&lt;p&gt;I created 2 (Contracts and Brands) new entities in Efficy, now I have a problem with a Word template.&lt;/p&gt;

&lt;p&gt;On the template I need information from &quot;Contracts&quot; and also from &quot;Brands&quot;. I added all needed fields to the template, but when running the template i.e. from the &quot;Contracts&quot; entity, the related information from &quot;Brands&quot; are empty. &lt;br&gt;
The same when I run the template from &quot;Brands&quot;, then &quot;Contracts&quot; informations are not filled.&lt;/p&gt;

&lt;p&gt;So it seems that I missed something but could not find what, any hint would be very helpful.&lt;/p&gt;

&lt;p&gt;Thanks in advance and best regards&lt;/p&gt;

&lt;p&gt;Stephan&lt;/p&gt;
</description>
<category>Efficy Integrations</category>
<guid isPermaLink="true">https://overflow.efficy.io/?qa=4826/word-template-fill-fields-from-relation-table-created-entity</guid>
<pubDate>Wed, 25 Sep 2019 09:11:24 +0000</pubDate>
</item>
<item>
<title>How to display some fields from the table PROD_OPPO in my word template?</title>
<link>https://overflow.efficy.io/?qa=3113/how-display-some-fields-from-table-prodoppo-word-template</link>
<description>&lt;p&gt;Hello,&lt;/p&gt;

&lt;p&gt;Please i want to display some fields from &lt;code&gt;PROD_OPPO&lt;/code&gt; table using an insert detail function or a run script, I got a field called &quot;Site&quot; in the relation (&lt;code&gt;PROD_OPPO&lt;/code&gt;) ,&lt;br&gt;
When i want to link a product to an opportunity i got fill in this field, &lt;/p&gt;

&lt;p&gt;Note: the &quot;Site&quot; field in not in the product table.&lt;/p&gt;

&lt;p&gt;Thanks,&lt;/p&gt;
</description>
<category>Efficy/ Client side</category>
<guid isPermaLink="true">https://overflow.efficy.io/?qa=3113/how-display-some-fields-from-table-prodoppo-word-template</guid>
<pubDate>Wed, 02 May 2018 14:55:16 +0000</pubDate>
</item>
<item>
<title>[Efficy 10] Image in template received by HTTP request</title>
<link>https://overflow.efficy.io/?qa=3021/efficy-10-image-in-template-received-by-http-request</link>
<description>&lt;p&gt;Hi,&lt;/p&gt;

&lt;p&gt;I have to add an image into a template which is received by HTTP request (post) from a serverscript. I don't find any way to append it on .rtf template.&lt;/p&gt;

&lt;p&gt;When the request is done, I save the image on HDD (I didn't found an other way to save the binary, if you have something, I take!) and now, I should add this image on template.&lt;/p&gt;

&lt;p&gt;How can I do it, please ?&lt;br&gt;
Thanks for your help,&lt;/p&gt;

&lt;p&gt;Best regards.&lt;/p&gt;
</description>
<category>WorkFlow / Serverscript</category>
<guid isPermaLink="true">https://overflow.efficy.io/?qa=3021/efficy-10-image-in-template-received-by-http-request</guid>
<pubDate>Tue, 03 Apr 2018 07:04:18 +0000</pubDate>
</item>
<item>
<title>Adding image (out of Product Record) in producttable in Word Template</title>
<link>https://overflow.efficy.io/?qa=2183/adding-image-out-product-record-producttable-word-template</link>
<description>&lt;p&gt;Adding image (out of Product Record) in producttable in Word Template&lt;/p&gt;

&lt;p&gt;==&amp;gt; has anyone done this before ?&lt;/p&gt;
</description>
<category>Efficy/ Client side</category>
<guid isPermaLink="true">https://overflow.efficy.io/?qa=2183/adding-image-out-product-record-producttable-word-template</guid>
<pubDate>Fri, 13 Jan 2017 11:01:11 +0000</pubDate>
</item>
<item>
<title>How to use a html formatted memo in a word template?</title>
<link>https://overflow.efficy.io/?qa=896/how-to-use-a-html-formatted-memo-in-a-word-template</link>
<description>&lt;p&gt;Hi, &lt;/p&gt;

&lt;p&gt;Is it possible to use the HTML formatted memo in a word template? (Efficy 2014)&lt;/p&gt;

&lt;p&gt;the tests I ve done so far only use the brute text memo.&lt;/p&gt;

&lt;p&gt;Regards,&lt;/p&gt;
</description>
<category>Efficy Partners</category>
<guid isPermaLink="true">https://overflow.efficy.io/?qa=896/how-to-use-a-html-formatted-memo-in-a-word-template</guid>
<pubDate>Fri, 30 Oct 2015 08:23:22 +0000</pubDate>
</item>
<item>
<title>EFFICY 2014 - Product table in Template</title>
<link>https://overflow.efficy.io/?qa=694/efficy-2014-product-table-in-template</link>
<description>&lt;p&gt;Hi,&lt;/p&gt;

&lt;p&gt;I've add a product table in a template with only &amp;lt;#F=NAME&amp;gt; and &amp;lt;#F=QUANTITY&amp;gt; but the merge document give me the following error on opening:&lt;br&gt;
Illegal qualified name character&lt;br&gt;
Where could that come from?&lt;/p&gt;

&lt;p&gt;I also need to add the product category name (R&lt;em&gt;FAMILY) in the products table. Can I replace PRODUCTS the tableviews entry Docu&lt;/em&gt;Prod by R_PRODUCTS to get that field? What could be the consequence on other processes?&lt;/p&gt;

&lt;p&gt;Thanks and Regards&lt;br&gt;
Anne&lt;/p&gt;
</description>
<category>Efficy/ Client side</category>
<guid isPermaLink="true">https://overflow.efficy.io/?qa=694/efficy-2014-product-table-in-template</guid>
<pubDate>Tue, 01 Sep 2015 13:50:56 +0000</pubDate>
</item>
</channel>
</rss>