C# Method like Base64String, but only alphanumeric (no plus or slash)

前端 未结 6 769
清歌不尽
清歌不尽 2021-02-13 11:25

is there any C# method that works similar to Convert.ToBase64String but doesn\'t generate anything except alphanumeric output?

Thanks!

6条回答
  •  我在风中等你
    2021-02-13 12:10

    You can use BitConverter.ToString() which will give you a hex string. However the resulting strings will be longer than Base64 encoding.

提交回复
热议问题