Thank you for your interest in Aspose.Words. Yes, you can use Aspose.Words to achieve your this. Aspose.Words can be used to read, modify and write Word® documents without utilizing Microsoft Word®. Aspose.Words supports document creation, content and formatting manipulation, mail merge abilities, comprehensive support of DOC, DOCX, RTF, WordprocessingML, HTML and PDF (requires Aspose.Pdf) formats.
You can learn more about Aspose.Words here
And download the latest .NET version of Aspose.Words from here
And the latest Java version from here
Please let me know if you would like to know anything else.