10 2018 档案

C# 将string 转换为二维码图片,然后转为base64字符串编码 。
摘要:需在nuget 添加此dll ///content字符串 public static string GetQRCode(string content, int moduleSize = 9) { var encoder = new QrEncoder(ErrorCorrectionLevel.M); 阅读全文

posted @ 2018-10-29 10:09 Ssumer 阅读(2436) 评论(0) 推荐(0) 编辑

Js jquery常用的身份证号码 邮箱电话等验证
摘要:刷了很多博客,https://www.cnblogs.com/hao-1234-1234/p/6636843.html 只有这个比较靠谱。 阅读全文

posted @ 2018-10-26 15:15 Ssumer 阅读(262) 评论(0) 推荐(0) 编辑

JS 前端 将图片转换为Base64利用H5 FileReader新特性
摘要:file = document.getElementById("image"); var file=file.files[0]; var fileName=file.name; if(file.type !== 'image/jpeg' && file.type !== 'image/png' && 阅读全文

posted @ 2018-10-24 11:42 Ssumer 阅读(2016) 评论(0) 推荐(0) 编辑

文件流转base64字符串
摘要:public static string GetBase64Data() { string path = @"C: \txt.jpg"; FileStream filestream = new FileStream(path, FileMode.Open); byte[] bt = new byte 阅读全文

posted @ 2018-10-24 11:37 Ssumer 阅读(5305) 评论(0) 推荐(0) 编辑

JSON string 在内存中转流 MemoryStream 代码,以及需要注意的问题utf-8问题
摘要:MemoryStream ms = new MemoryStream(System.Text.Encoding.UTF8.GetBytes("字符串"); string str = Convert.ToBase64String(ms.ToArray()); 阅读全文

posted @ 2018-10-18 14:15 Ssumer 阅读(618) 评论(0) 推荐(0) 编辑

C# 打开文件 保存文件
摘要:string path = @"C: \Users\users\Desktop\xxxx.txt";// 文件路径 FileStream filestream = new FileStream(path, FileMode.Open); byte[] bt = new byte[filestream 阅读全文

posted @ 2018-10-18 10:08 Ssumer 阅读(4457) 评论(0) 推荐(0) 编辑

常见Json字符串反序列化处理方式总结
摘要:常用来处理Json字符串序列化 反序列化组件:Newtonsoft.Json (https://www.newtonsoft.com/json) 参考资料https://www.cnblogs.com/shang201215019/p/7907655.html 一丶JObject Class () 阅读全文

posted @ 2018-10-17 11:29 Ssumer 阅读(2762) 评论(0) 推荐(0) 编辑

如何取未知Json字符串 某个主键取对应的Value
摘要:需添加引用using Newtonsoft.Json; string strJon "Json 字符串"; JObject obj = JObject.Parse(strJon ); string serial_number = obj["status"].ToString(); 更多Json的操作 阅读全文

posted @ 2018-10-15 22:19 Ssumer 阅读(427) 评论(1) 推荐(0) 编辑

导航

< 2025年3月 >
23 24 25 26 27 28 1
2 3 4 5 6 7 8
9 10 11 12 13 14 15
16 17 18 19 20 21 22
23 24 25 26 27 28 29
30 31 1 2 3 4 5
点击右上角即可分享
微信分享提示