Issue: After creating a merge document and populating the document with merge fields, the document will perform correctly, i.e. all merge fields are populated. After the document is saved, however, opening it and trying to duplicate the merge fails. The merge fields appear to be recognized, as I can highlight them, but the preview no longer shows the results for each record (or any record).
After re-opening the document and selecting the merge source, I can add mergefields that do get populated, but the existing fields do not get populated.
I have tried this with documents converted from MS Word 2021 and also with documents created online from scratch, with identical inability to achieve expected results.
OnlyOffice online, from Windows 10, Firefox 107.0. also Chromium 107.0 (Brave 1.45.127)
Can you please help me create a document with mergefields that I can re-use? One-off mailmerge documents (i.e. ones where mergefields must be re-inserted every time) are not useful to me.
Thanks in advance.
burque505
Hello @burque505
I’m trying to reproduce the situation. Would you mind providing us with a videofile where you are reproducing the situation (step-by-step)? Also please send us examples of files (xlsx and docx) where we can reproduce the issue.
1 Like
Thanks for responding, @Alexandre. I will post some sample files later today or tomorrow, and I hope a video or animated GIF at least, as soon as work permits. EDIT: I’ll try to attach files and animated GIF now.Processing: mergefail-download-2022-11-23.zip…
So far I can’t seem to attach my ZIP archive with sample files. I’ll keep trying - if I can’t do it I’ll supply a link.
EDIT: I sent files by email in response to your post. Please let me know if they don’t arrive.
Thank you!
mergefail.mp4
Thank you, I’ve got files. We are checking the situation.
1 Like
Thank you for provided data. We found a match with known bug (internal number - 59709). We are working on it already.
We will notify you when we have something to share. Thank you for valuable data!
1 Like
Hi,
is there any api to insert the mailmerge fields in plugin?
Hello @softboy99
Please provide us with exact scenario. There’s a sample of how to use MailMerge method: MailMerge
However, we need the entire scenario to check it out.
hi
The senario: we need insert mailmerge field into docx in plugin with code. I checked the documentation, found there is sample,but don’t know how to get the cursor paragraph.
function onDropEvent(data) {
console.log('==========data=======>', data);
Asc.scope.field = data;
window.Asc.plugin.callCommand(function() {
var oDocument = Api.GetDocument();
let oParagraph = oDocument.GetElement(0);///////////////don't know how to get the paragraph under cusor
if (oParagraph) {
var oRun = Api.CreateRun();
oRun.AddText(Asc.scope.field);
oParagraph.AddElement(oRun);
oRun.WrapInMailMergeField();
}
}, undefined, undefined, function(result) {
paste_done = true;
});
}
Hi
@Alexandre , is there any unclear?
Hello @softboy99
As far as I understand, you’re already discussing this case in another thread: How to get current paragraph of .docx document under cursor?
For future requests, please avoid duplicating requests in different topics.