Page 1 of 1

I don't know how to solve this problem :(

PostPosted: Tue Jul 14, 2015 8:39 pm
by yangcom0505
Hi All,
I am quite new to docx4j.

I have been in trouble :cry:

I made docx template file and setted xpath using "Word 2007 Content Control Toolkit" and generated xml file.

but I leand that I should not using toolkit. instead I leand I should use OpenDoPE.

this link give me little hint. I don't understand well. (http://www.docx4java.org/forums/data-binding-java-f16/need-help-in-repeated-binding-t827.html)



anyway,

how can i generate dynamic word file?

I must make a lump Questions & Answers dynamically.

my plan
1)make template docx file (using content control)
2)xpath setting to docx for xml mapping
3)xml data mapping(binding) to template docx file

and then present data in word.

but I want to know how to generate repeat q&a area dynamically.

I uploaded sample image file.

plz show code sample :cry:

It's too difficult for me

Re: I don't know how to solve this problem :(

PostPosted: Wed Jul 15, 2015 8:50 pm
by jason
Speaking generally, many of the hundreds of document assembly systems out there generate their question form interface. But they all re-invent the technology.

In the context of content control data binding, the hierarchical structure of content controls leads naturally to hierarchical questions.

Its nested repeats and conditions which make things complex.

Plutext has code to do all this - both the authoring interface and the user runtime. We're mulling over open sourcing it.

Re: I don't know how to solve this problem :(

PostPosted: Thu Jul 16, 2015 4:24 pm
by yangcom0505
Thank you, Jason

can you solve my problem?

and Another question occurred.

I made word.

just
name: [content control]
age : [content control]
캡처.JPG
new word
캡처.JPG (20.59 KiB) Viewed 1589 times


and I referenced ContentControlsInfoStructure.java, ContentControlsMergeXML.java and CreateDocxWithCustomXml.java (docx4j-git)

so if xpath is set, when i create a word file, make customxml(when unzip .docx)

but i don't know how to programmatically set the xpath.




e.g) word 2007 content tool kit -> Edit view coding -> appear folder and file in bind view ->drag and drop file to xpath

summary
I want to code these series of processes using the docx4j.
I want to bind content control to customxml.


I uploaded my work.

in my case In eclipse make class and copy and paste ContentControlsInfoStructure.txt.

and i uploaded two invoice.docx. these little different.

one not run and the other you can run.

I want to run that should not be run

running docx was set xPath with word tool kit

not running docx was not set xpath.

I want to programmatically set xpath.


Thanks in advance