Forum


Replies: 3   Views: 1269
Error mergedocx using override numberings
Topic closed:
Please note this is an old forum thread. Information in this post may be out-to-date and/or erroneous.
Every phpdocx version includes new features and improvements. Previously unsupported features may have been added to newer releases, or past issues may have been corrected.
We encourage you to download the current phpdocx version and check the Documentation available.

Posted by organizzazione  · 08-03-2021 - 11:11

Hi,
I have a problem with the MergeDocx. In the original doc I have a numeric list while in the final document of the MergeDocx method a different list comes out
  1. A....;
  2. R......;
  3. T.......

 

it becomes

Article I.A.......;

Article II.R.....;

Article III.T.........

 

I have installed PHPDocx 11.0 Premium and i use this code:

/
            $merge = new \MultiMerge();
            $merge->mergeDocx($firstDoc, $arrayDocs, $fileFullPathDocx, array(
                'mergeType' => 1,
                'lineBreaks' => 2
            ));

Any suggestions?

Thank you

 

 

 

Posted by admin  · 08-03-2021 - 11:28

Hello,

Maybe the DOCX is using a style name that requires setting the enforceSectionPageBreak option as true (we recommend you to enable this option in mergeDocx and try again) or it uses a not supported style. The current testing version of phpdocx includes some improvements when working with mixed numbering styles in custom paragraph styles. Please send to contact[at]phpdocx.com both documents and if you are using the classic or namespaces package, and we'll test them using the current testing version of mergeDocx; if they use some not supported style we'll add support and send the class updated.

Regards.

p.s. we have removed the email from you username account, so it won't appear in the forum.

Posted by organizzazione  · 08-03-2021 - 13:39

 

I tried with the parameter enforceSectionPageBreak set true but it has no effect. I sent you an email with the docx.

Posted by admin  · 08-03-2021 - 14:48

Hello,

UPDATE: phpdocx 13.5 added support for this specific style when merging documents.

Thanks for sending the requested documents. The issue is a not supported style when applying override numberings that appear multiple times with the same ID; the current testing branch of phpdocx includes support for this case (all users with the latest version of phpdocx can request this update to add support for this specific case sending an email to contact[at]phpdocx.com).

We have sent to your email the updated class.

Regards.