Encoding.ASCII not available in Silverlight is there a alternative?

前端 未结 2 1783
太阳男子
太阳男子 2021-01-22 16:53

I have the following line of code for a Windows forms application:

return Encoding.ASCII.GetBytes(chars.ToArray());

This line worked fine, but

相关标签:
2条回答
  • 2021-01-22 17:01

    Probably using Encoding.UTF8 will solve your problem, but you can always use the Silverlight Encoding Generator and get any encoding you'd like!

    0 讨论(0)
  • 2021-01-22 17:15

    Try using Encoding.UTF8 - Silverlight is unicode only.

    0 讨论(0)
提交回复
热议问题