Because of the tight schedule, I have to study the above toolkit in a few cases. Now I use javascript to operate the ActiveXObject control and replace the bookmarks in the word template. Because of the tight schedule, I have to study the above toolkit in a few cases. Now I use javascript to operate the ActiveXObject control and replace the bookmarks in the word template.
Recently, you need to export data to word and edit and print the data.
I have thought of several solutions:
1. Use jacob.
2. Use apache poi.
3. Use itext.
Because of the tight schedule, I have to study the above toolkit in a few cases. Now I use javascript to operate the ActiveXObject control and replace the bookmarks in the word template.
Prerequisites:
1. the browser security level is reduced. You can use the ActiveXObject control.
2. Install office word.
Currently, you can replace a single bookmarks, multi-row table bookmarks, and images to meet your needs. However, there are still many ways to use word that are unclear. Most of the Web applications use VB. If you have any questions, you can contact us.
The following describes my design implementation ideas:
First of all, define the word template and add the tag to the place to be replaced. Menu-insert-bookmarks, INPUT attribute names, such as year, date, pic1, and voList.
Print page:
The printed data needs to be taken out from the background, and taken a single vo (an object) as a group, or voList (a list set of objects) after the data is obtained for a group of organized pages, replace the data.
The data is organized as follows:
Usage: