https://issues.apache.org/bugzilla/show_bug.cgi?id=57008
--- Comment #4 from Dominik Stadler <[email protected]> --- I did some searching and found a few places where this is discussed: * http://cpansearch.perl.org/src/JMCNAMARA/Excel-Writer-XLSX-0.74/lib/Excel/Writer/XLSX/Package/SharedStrings.pm # Excel escapes control characters with _xHHHH_ and also escapes any # literal strings of that type by encoding the leading underscore. So # "\0" -> _x0000_ and "_x0000_" -> _x005F_x0000_. # The following substitutions deal with those cases. # Escape the escape. $string =~ s/(_x[0-9a-fA-F]{4}_)/_x005F$1/g; # Convert control character to the _xHHHH_ escape. $string =~ s/([\x00-\x08\x0B-\x1F])/sprintf "_x%04X_", ord($1)/eg; * http://public.vrac.iastate.edu/~charding/HCI574_lecture_notes/lecture24/XlsxWriter-0.5.3/xlsxwriter/sharedstrings.py # Excel escapes control characters with _xHHHH_ and also escapes any # literal strings of that type by encoding the leading underscore. # So "\0" -> _x0000_ and "_x0000_" -> _x005F_x0000_. # The following substitutions deal with those cases. # Escape the escape. string = re.sub('(_x[0-9a-fA-F]{4}_)', r'_x005F\1', string) # Convert control character to the _xHHHH_ escape. string = re.sub(r'([\x00-\x08\x0B-\x1F])', lambda match: "_x%04X_" % ord(match.group(1)), string) * https://social.technet.microsoft.com/Forums/sharepoint/en-US/a00949a6-4b2d-4cde-875f-850870b76900/ssrs2012-export-to-excel-excel-found-unreadable-content?forum=sqlreportingservices So there seems to be a way to escape characters this way and also a way to escape the escape-sequence to allwo to embed this in literal form. -- You are receiving this mail because: You are the assignee for the bug. --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
