0
votes

We have a wcf service containing some methods and occasionally it failes when it tries to serialize the data. The exception is below(Also contains the stack trace).

Any solution for this ? Also, Why does this happen sporadically not all the time ? The data that is returned remains the same all the time.

[System.Text.EncoderFallbackException]: Unable to translate Unicode character \uDF98 at index 1 to specified code page. CallStack: at System.Text.EncoderExceptionFallbackBuffer.Fallback(System.Char charUnknown,System.Int32 index) [IL: 0x2B][Native: 0xB7] at System.Text.EncoderFallbackBuffer.InternalFallback(System.Char ch,System.Char*& chars) [IL: 0xE7][Native: 0x125] at System.Text.UTF8Encoding.GetBytes(System.Char* chars,System.Int32 charCount,System.Byte* bytes,System.Int32 byteCount,System.Text.EncoderNLS baseEncoder) [IL: 0x21D][Native: 0xD93D94] at System.Text.UTF8Encoding.GetBytes(System.Char* chars,System.Int32 charCount,System.Byte* bytes,System.Int32 byteCount) [IL: 0x54][Native: 0x4C] at System.Xml.XmlStreamNodeWriter.UnsafeGetUTF8Chars(System.Char* chars,System.Int32 charCount,System.Byte[] buffer,System.Int32 offset) [IL: 0x80][Native: 0x263CC3] at System.Xml.XmlBinaryNodeWriter.UnsafeWriteText(System.Char* chars,System.Int32 charCount) [IL: 0x3C][Native: 0x8B] at System.Xml.XmlBinaryNodeWriter.WriteText(System.String value) [IL: 0x39][Native: 0x3C] at System.Xml.XmlBaseWriter.WriteString(System.String value) [IL: 0x4D][Native: 0x9E] at System.Runtime.Serialization.XmlObjectSerializerWriteContext.WriteString(System.Runtime.Serialization.XmlWriterDelegator xmlWriter,System.String value,System.Xml.XmlDictionaryString name,System.Xml.XmlDictionaryString ns) [IL: 0x29][Native: 0x53] at WriteArrayOfstringToXml(System.Runtime.Serialization.XmlWriterDelegator ,System.Object ,System.Runtime.Serialization.XmlObjectSerializerWriteContext ,System.Runtime.Serialization.CollectionDataContract )[Native: 0xDC]

1

1 Answers