摘要: 1.需要添加的引用 using iTextSharp.text;using iTextSharp.text.pdf; 2.图片地址转新建PDF /// <summary> /// 图片转pdf /// </summary> /// <param name="jpgfile">要转换的图片的路径</p 阅读全文
posted @ 2022-09-08 10:40 御翼仁粨狩 阅读(385) 评论(0) 推荐(0)
摘要: public static (List<SqlParameter> ListParameter, string Error) MakeSQLParamterListFromSQLAndClass<T>(string strSQL, T MyCls) { List<SqlParameter> lsSP 阅读全文
posted @ 2022-07-04 17:46 御翼仁粨狩 阅读(72) 评论(0) 推荐(0)
摘要: public static (T Data, string Error) DataRowToClass<T>(DataRow dr) { T obj = Activator.CreateInstance<T>(); //活化剂类实例化泛型对象 string strError = ""; if (dr 阅读全文
posted @ 2022-07-04 17:42 御翼仁粨狩 阅读(39) 评论(0) 推荐(0)
摘要: 1.方法 public static (List<T> Data, string Error) DataTableToClassList<T>(DataTable dt) { List<T> lsData = new List<T>();//无数据的情况下返回NULL-标准化 string strE 阅读全文
posted @ 2022-07-04 17:41 御翼仁粨狩 阅读(73) 评论(0) 推荐(0)
摘要: 1.地址获取Image文件 public static Image UrlToImage(string url) { WebClient mywebclient = new WebClient(); byte[] Bytes = mywebclient.DownloadData(url); usin 阅读全文
posted @ 2022-07-04 17:36 御翼仁粨狩 阅读(1076) 评论(0) 推荐(0)
摘要: using Newtonsoft.Json; using System.Text; using System; namespace Core.API.dahua{ /// <summary> /// 门组接口 /// </summary> public class Menzu { /// <summ 阅读全文
posted @ 2021-03-17 18:18 御翼仁粨狩 阅读(708) 评论(0) 推荐(0)
摘要: 首先 我们得有一个实体 public class Men { /// <summary> /// id /// </summary> public int id { get; set; } /// <summary> /// 名称 /// </summary> public string name 阅读全文
posted @ 2021-03-15 11:32 御翼仁粨狩 阅读(1371) 评论(0) 推荐(0)
摘要: 1.运行方法写在Global.asax文件中 public void Application_BeginRequest(Object sender, EventArgs e) { //过滤Post参数 string url = this.Request.Url.ToString(); string  阅读全文
posted @ 2020-09-23 11:39 御翼仁粨狩 阅读(303) 评论(0) 推荐(0)
摘要: 1.添加引用 using System.Drawing; 2.画图方法 /// <summary> /// 画图 /// </summary> /// <param name="entity">实体 Model.ChargeInfo</param> /// <param name="pathbg"> 阅读全文
posted @ 2020-09-15 18:00 御翼仁粨狩 阅读(419) 评论(0) 推荐(0)
摘要: if (Identification.Length == 18)//处理18位的身份证号码从号码中得到生日和性别代码 { string age = Identification.Substring(6, 4) + "-" + Identification.Substring(10, 2) + "-" 阅读全文
posted @ 2020-09-07 12:01 御翼仁粨狩 阅读(2805) 评论(0) 推荐(0)