18 January 2026:
Sahi Pro is an enterprise grade test automation platform which can automate web, mobile, API, windows and java based applications and SAP.
This forum is now archived and is in read-only mode. Please continue discussions on our improved new Sahi Pro Community forum.
Sahi Pro is an enterprise grade test automation platform which can automate web, mobile, API, windows and java based applications and SAP.
Problems with character encoding in Sahi scripts
Hi,
I've had a problem when sahi scripts contains non ANSI characters, like vocals stressed (ej:
I've had a problem when sahi scripts contains non ANSI characters, like vocals stressed (ej:
Comments
Try using this:
_setSelected(_select("area_tested"),"Administraci\u00D3n - Alarmas"); //can't verify it right now but hope it is the right unicode value
We need to give the unicode values in such cases.
Regards,
Pankaj.
I researched about UTF-8 and found why the "" characters are printed at the beginning of the script. It is becaused of an UTF-8 variation named Byte-order mark. I hope to find a way to eliminate these characters.
"Many Windows programs (including Windows Notepad) add the bytes 0xEF,0xBB,0xBF at the start of any document saved as UTF-8. This is the UTF-8 encoding of the Unicode byte-order mark. This causes interoperability problems with software that does not expect the BOM. In particular:
* It removes the desirable feature that UTF-8 is identical to ASCII for ASCII-only text. For instance a text editor that does not recognize UTF-8 will display "" at the start of the document, even if the UTF-8 contains only ASCII and would otherwise display correctly. It is for example possible to introduce Unicode into an existing computer language and compiler by adding some API for input/output, and use an external UTF-8 text editor when editing text strings. However such a compiler would not accept the BOM, which must be removed manually".
To eliminate the "" characters I used Ultraedit and disabled the "Auto Detect UTF-8 Files" in order to visualize the extra characters and erase them. Then I apply your advise and sustitute vocals stressed by its corresponding UTF-8 values:
Here you can find a chart for unicode values:
http://www.ssec.wisc.edu/~tomw/java/unicode.html
Regards,
Pankaj.