Hi Morgan,

"Morgan V. Cundiff" writes:
> Can someone tell me how to search for hex character in emacs?  [...]
>
> Error at byte 13070 of file:/C:/projects/DHc2xml/dhc_fa/v1out/astruc.sgm:
>      [java]   Error reported by XML parser: invalid UTF-8 byte (check the
> XML declaration) (code: 0xfc)
>
>[...]
>
> How do search for hex character 0xfc in emacs?

The byte value such as Saxon is complaining about does usually not
exist in the Emacs buffer because Emacs will decode/encode into its
internal format when reading/writing.

You can try M-x hexl-find-file to get a detailed view of the bytes in
your file and to search for the byte in question.

Before you do that you may want to try M-x describe-coding-system RET
RET in the original buffer to see if Emacs actually will save the file
correctly in UTF-8 as Saxon expects.  If not, you can change the
coding-system with M-x set-buffer-file-coding-system RET utf-8 RET.
If this is the problem you can add a "coding" file variable to your
file, see (info "(Emacs)File Variables"), to make sure Emacs will use
UTF-8 for the file in the future.


benny



Reply via email to