We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

Get plain text from Html Text

I have html text and I need to create it plain text from this Html text.

Can u please tell me how can i do this in Aspose.

Html Text-->

Hello Nalinee!!

Required plain text is--> Hello Nalinee!!

Thank you.

Hi

<?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" />

Thanks for your inquiry. Just load HTML into Aspose.Words.Docuemnt object and then get text as described here:

http://www.aspose.com/documentation/java-components/aspose.words-for-java/howto-extract-text-only.html

You can just open HTML using code like the following:

Document doc = new Document("in.html");

or use insertHtml method:

http://www.aspose.com/documentation/java-components/aspose.words-for-java/com/aspose/words/documentbuilder.html#insertHtml(java.lang.String)

Hope this helps. Please let me know if you need more assistance, I will be glad to help you.

Best regards.