Arthur Burma wrote:so i have used this expression , but maybe a better way to set this independant of the order on attribute::value result
Well, assuming we are actually talking about DOM programming here (your code certainly looks like that):
you should be getting an Attr node from that XPath expression. So why wouldn't you just use its setValue() method, as per the documentation?
I'm saying that based on the fact that you haven't told us that you are having a problem, or what it is if there is a problem. So I'm just guessing at things to say. So perhaps you could do that. If there are exceptions, show us the stack trace. If some output differs from what you think it should be, show it to us and tell us what the difference is.