I am developing a webservice to create an odt document with odf toolkit. I did use below code to create a new document but i am getting an casting error. What o you think about it? How can i create formatted(colored etc) text? Thanks
My Code Just
    try
{
    TextDocument outputOdt=TextDocument.newTextDocument();
    outputOdt.save("C:\\Users\\TheIntersect\\Documents\\NetBeansProjects\\webWord\\web\\Documents\\docx\\quick.odt");
    return "Succesfull";
}
catch (Exception e)
{
    return e.getMessage();
}
Error
org.odftoolkit.odfdom.pkg.OdfAlienElement cannot be cast to org.odftoolkit.odfdom.dom.meta.MetaInitialCreatorElement