上一页 1 ··· 20 21 22 23 24
摘要: 1. 新建项目 windows桌面 windows服务 2. 右击 添加安装程序 3. 右击 属性 4. 右击service1查看代码 public partial class Service1 : ServiceBase { private int num = 1; public Service1 阅读全文
posted @ 2020-04-08 11:19 一介桃白白 阅读(440) 评论(0) 推荐(0)
摘要: 新建一个 DataLog类 用来存放生成Log日志方法 #region 写日志 public void WriteLogEx(string sendJson, string code = "", string msg = "", string fileName = "") { string path 阅读全文
posted @ 2020-04-08 09:09 一介桃白白 阅读(240) 评论(0) 推荐(0)
摘要: 备注:注意内网环境,(要VPN或在现场内网操作) 1. 在程序中打开VS中的命令行 2. 从wsdl路径下载至cs文件 情景一:客户有提供VPN能从本地访问 输入命令:wsdl /language:c# /n:CHEER.PresentationLayer /out:文件存储路径 http://10 阅读全文
posted @ 2020-04-07 16:49 一介桃白白 阅读(3354) 评论(0) 推荐(0)
摘要: 添加Nuget包 添加引用 using Newtonsoft.Json; List转Json List<InfoJson> JsonsList = new List<InfoJson>(); string jsonStr= JsonConvert.SerializeObject(JsonsList  阅读全文
posted @ 2020-04-07 09:56 一介桃白白 阅读(9124) 评论(0) 推荐(2)
摘要: 这里选择空的模板,有需要的可以选择MVC模板。 创建好项目后添加EF的NuGet包 新建 MyDBContext 类用来连接数据库(记得添加引用 using System.Data.Entity;) public class MyDBContext:DbContext { // 注:这是连接sqls 阅读全文
posted @ 2020-03-24 16:17 一介桃白白 阅读(630) 评论(0) 推荐(0)
摘要: 使用目的:方便做统计 或 查询哪个表压力较大从而进行优化等功能。 USE [库名] SELECT a.name, b.rows FROM sys.sysobjects AS a INNER JOIN sys.sysindexes AS b ON a.id = b.id WHERE (b.indid 阅读全文
posted @ 2020-03-23 09:30 一介桃白白 阅读(440) 评论(0) 推荐(0)
摘要: 例如:模糊查询班级中所有姓 “李、刘” 的学生,只需要在查询的时候输入一个 “L” 进行查询。 string PYM = ""; foreach (char c in PersonName) { if ((int)c >= 33 && (int)c <= 126) { //字母和符号原样保留 PYM 阅读全文
posted @ 2020-03-19 11:52 一介桃白白 阅读(850) 评论(0) 推荐(0)
上一页 1 ··· 20 21 22 23 24