unfortunately the snippet you posted is insufficient to understand what you want to do; for instance, you say that you have a problem with importNode(), but this function is never used in the code.
Also, you use variables like "dn" and "de", but I can only guess you are referring to "node" and "element".
And finally, the replace() function seems to do some work, but we don't see what it does nor with which arguments it is invoked.
Alberto
At 12.25 27/01/2004 -0800, Jimmy Yu wrote:
Hello,
I am at a lost as to why my importNode doesn't seem to work... This is a snippet of my code... Using version 2_4_0 and VC++ 6.0 my variable doc is currently global, will later be changed to member in my class.
node = (DOMNode*)doc->getDocumentElement();
element = (DOMElement*)dn;
list = de->getElementsByTagName(feature);
count = list->getLength();
cout << "count is " << count << endl; // displays correct #
replace(DOMNode* newnode); // update/replace the old node with a new node.
// function does not report any error or exception.
node = (DOMNode*)doc->getDocumentElement(); element = (DOMElement*)dn; list = de->getElementsByTagName(feature); count = list->getLength(); cout << "count is " << count << endl; // displays one less why?? my second question is, if I change my second getDocumentElement() to getFirstChild() my program will crash, anyone have an idea why that is happening also?
Thanks in advance. -- Jimmy ____________________________________________ Taxes and golf are alike, you drive your heart out for the green, and then end up in the hole. - Source unknown
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]