Ian,

that was simple, it worked immediatly.

Thanks,
Hans

From: Ian Roberts <[EMAIL PROTECTED]>
Reply-To: [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Subject: Re: problem with passing Xerces Document to Xalan
Date: Mon, 26 Mar 2001 15:51:25 +0100 (BST)

On Mon, 26 Mar 2001, hans steen wrote:

> Can anyone tell me what is wrong.
> I'm using Xerces to make an Document-object in this way:
>
>   doc= new DocumentImpl();
>   Element root = doc.createElement("dices:nshans");
>   root.setAttribute("xmlns:dices", "http://www.hans.com";);
>
>   Element item = doc.createElement("dices:result");
>   item.appendChild(doc.createTextNode("value"));
>   root.appendChild(item);
>
>   doc.appendChild( root );

I'm not sure this will create the correctly namespaced elements.  Try
doing:

Element root = doc.createElementNS("http://www.hans.com";, "dices:nshans");
Element item = doc.createElementNS("http://www.hans.com";, "dices:result");

to create the elements.

Ian

--
Ian Roberts, Software Engineer        DecisionSoft Ltd.
Telephone: +44-1865-203192            http://www.decisionsoft.com




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


_________________________________________________________________________ Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com.


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



Reply via email to