Hello everyone. I have been trying to implement the following solution in my web application by various means, eventually ending up trying to use the Word interop assemblies but all advice tells me not to use interop on a web server. Hence, exploring Aspose.
The web application needs to capture a legal document that can be edited before saving. A number of fields, such as dates are completed that eventually go into forming the body of the document. We use Telerik components on the site so we used their editor to give us editing capabilities on the web page. This uses html to format the document. It is very similar to using the editor I'm typing this in.
Some mail merge type operations are performed to add a company name and address. The letter typically is three pages long. I had set up a Word template consisting of a graphic in a header and footer for the first page and on subsequent pages no header and the same footer as a continuation page. I then copied the text from the editor into the Word template. At first it pasted the raw html but I did some work on it to remove the html tags and use Word commands to keep the formatting (bold, underline etc.) to get the text how I wanted it.
My main problems were with printing. The editor control allows me to print but dealing with the headers and footers was impossible via html (or it was to me anyway!) and it wasn't very good at dealing with page breaks so I placed the text into Word so it could use a template that did what I wanted when I pasted the text into it. It could then be printed from there.
WIll Apose allow me to do this?
- Does it remove the need for me to get rid of the html tags and keep the formatting?
- Will I be able to use an asp.net server-side button to give me a print facility to get a hard copy of the document? This button will also update a database to say the document has been sent for printing.
- Will I be able to create a template (in Word?) so that it will deal with the headers and footers in the way I described above?
- Does Aspose allow me to manipulate text to provide formatting, such as bold, italic etc.
Other questions are:
- How does it work with the web server?
- Is it all server based or is some of it client based?
I had trialed the OfficeWriter product (can't remember who does it) a while ago but it wasn't very easy to use in that it embedded a document in an SQL server reporting service report. Does Apsose work in a similar manner to this. I'm hoping I can just create a regular Word template with the headers and footers and 'copy and paste' the html text in the editor control into the template.
Sorry it's a long message but I'm rather short of time to get this working and I need to try and think of all the questions to ask in as few emails as possible. I hope it all makes sense!
Thanks for your help.