How were you building your instance. I know there are certain cases
where those options will not work (like parse(String)) and those are
known and working as designed. You may want to search the mailing
lists to see if this is one of those cases.
Otherwise, the other option might be to write something up using the
xml cursor APIs if you are going to be doing this a lot
-Jacobd

On 8/20/07, Ole Matzura <[EMAIL PROTECTED]> wrote:
> Hi Jacob,
>
> Thanks for answering.. unfortunately this didn't work.. I tried a number
> of combinations with different XmlOptions etc without any luck..  Should
> I file a bug report somewhere?
>
> anyhow, I worked around it for now by removing those not used manually..
>
> best regards,
>
> /Ole
> eviware.com
>
> Jacob Danner wrote:
> > Hi Ole,
> > You should try the XmlOptions method(s):
> >
> >  XmlOptions   setSaveAggressiveNamespaces()
> >           Causes the saver to reduce the number of namespace prefix
> > declarations.
> >
> > Depending on how you are building your document this should work.
> > Hope this helps,
> > -Jacob Danner
> >
> >
> > On 8/20/07, Ole Matzura <[EMAIL PROTECTED]> wrote:
> >
> >> Hi!
> >>
> >> Is there any way to remove unused namespaces from an XmlObject when it
> >> is being saved? My situation is the following:
> >>
> >> 1) Parse a document with a large number of namespaces
> >> 2) Change the content of the document so that many of the namespaces are
> >> not used anymore
> >> 3) Save the document
> >>
> >> Now I still get a long list of xmlns:... definitions in the document
> >> element although there is no content that actually uses them..
> >>
> >> Thanks for any tips!
> >>
> >> regards,
> >>
> >> /Ole
> >> eviware.com
> >>
> >>
> >> ---------------------------------------------------------------------
> >> To unsubscribe, e-mail: [EMAIL PROTECTED]
> >> For additional commands, e-mail: [EMAIL PROTECTED]
> >>
> >>
> >>
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> >
> >
> >
> >
> >
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to