Hello,
I'm trying to use this code to replace character "à" with "a'":
XmlCursor cursor = xmlObj.newCursor();
while( !cursor.toNextToken().isNone() ){
switch( cursor.currentTokenType().intValue() ){
case TokenType.INT_TEXT:
case TokenType.INT_ATTR:
{
String strval = cursor.getTextValue();
strval = strval.replaceAll("à","a'");
try{
cursor.setTextValue( strval );
}catch(IllegalStateException e){
//discard this
}
}
}
}
but the document remains unchanged, what's my mistake?
Many thanks
Best regards
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]