[xml] Set property

I am trying to set a property in a xml document, but I didn't get it. The node has 2 properties, Description and Value, I can set the first one, but I can't change the value of the second one. The xml is:

<MODULE Description="REM" Value="00">
        <Unit Description="Unit type" Value="01"/>

I have tried with
xmlNodeSetContent(node, "xx");
when node is "/MODULE/CONFIGURATION/Unit/@Value"
and it was impossible (segmentation fault)
but I can do it if node is "/MODULE/CONFIGURATION/Unit/@Description"

Also with
xmlSetProp(node, "Value", "xx");
when node is "/MODULE/CONFIGURATION/Unit"
is not possible but I can do
xmlSetProp(node, "Description", "xx");

I don't understand, because xmlGetProp and xmlNodeGetContent always works fine, but not Set option,
What happen?

Thank you.

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]