- 博客(80)
- 收藏
- 关注
转载 预热请求,多任务发送请求并获取请求结果保存到数据库中
class MyInit { ALiPayHelper aLiPayHelper = new ALiPayHelper(); HttpClientRequest request = new HttpClientRequest(); public void Init() { ...
2018-10-30 13:49:00
227
转载 .net调用接口需要传header
/// <summary> /// WPS API接口调用 /// </summary> /// <param name="requestMethod">请求方式(get,post,put,delete)</param> /// <param name="re...
2018-07-04 09:33:00
461
转载 .net async await
using System;using System.Net.Http;using System.Threading;using System.Threading.Tasks;namespace CookBook{ class Program { static void Main(string[] args) ...
2016-06-27 17:42:00
137
转载 sql替换字符
declare @name varchar(100)='"acct_name"',@card varchar(100)='"id_no"'SELECT TOP 100 stuff( STUFF(Json, CHARINDEX(@name, Json) + LEN(@name) + 2, CHARINDEX('...
2016-02-23 18:09:00
127
转载 sql事务
using System;using System.Collections.Generic;using System.Data.SqlClient;using System.Reflection;using System.Text;using System.Text.RegularExpressions;using ZJS.DBUtility;name...
2015-09-25 18:16:00
119
转载 工具类
/// <summary> /// post方法 /// </summary> /// <param name="serverUrl"></param> /// <param name="reqJson"></param> ...
2015-09-14 09:04:00
103
转载 Nlog配置
<configSections> <section name="nlog" type="NLog.Config.ConfigSectionHandler, NLog"/> </configSections> <nlog xmlns="http://www.nlog-project.org/schemas/NLog.x...
2015-09-12 14:31:00
141
转载 C#使用Func
using System;namespace Bank{ public class Pay { public string Send<T, T2>(Func<T, Bank.User, string> funcDo, T context, Bank.User model, Func<string, str...
2015-09-07 23:00:00
125
转载 游标使用
SET NOCOUNT ONDECLARE @poc INT,@PurchaseOrderId NVARCHAR(40),@EBELP INT,@sql NVARCHAR(max),@PurchaseOrderDetailId NVARCHAR(40),@ExpenseShareId NVARCHAR(40),@DetailCursor CURSOR, --订单明细游标...
2015-05-15 10:37:00
75
转载 多线程同步
private System.Threading.ReaderWriterLock rwl; public DataBase() { rwl = new System.Threading.ReaderWriterLock(); } /// <summary> ...
2015-04-18 13:25:00
69
转载 c#执行并行任务之Parallel与TaskFactory
本文转载自 http://www.cnblogs.com/icyJ/p/Parallel_TaskFactory.html很厉害的帖子Barrier _bar;int _maxLength = 20, _maxChannel = 2;//同时最多2条通道,每条通道最多20个数据bool _isCancel = false;private void btnWrite...
2015-04-17 17:30:00
183
转载 C#异步
using System;using System.Threading;using System.Runtime.Remoting.Messaging;using System.Collections.Generic;namespace PurchaseSystem.Component{ public enum FlowType { ...
2015-04-15 18:07:00
95
转载 编码问题
js中escape编码在后台+会被替换成空格可以使用encodeURIComponent解决转载于:https://www.cnblogs.com/daixingqing/p/4267419.html
2015-02-02 11:40:00
98
转载 数据库全文检索对比
declare @t1 datetime,@total intset @t1=GETDATE()select rowId,BuildName from (select top 2896 row_number() over( order by id asc) rowId,BuildName from tbl_data_House order by id asc) tb w...
2014-02-24 16:14:00
146
转载 Excel导出
<!DOCTYPE html><html><head> <title>ASP.NET版Memcached监控工具</title> <style type="text/css"> ul { list-style: none;...
2013-12-30 11:25:00
96
转载 上传进度基础
HttpFileCollection hfc = Request.Files; if (hfc.Count > 0) { FileStream fs; Stream _stream; int btLen = 10000; byte[] _b...
2013-09-30 12:47:00
93
转载 js将方法作为参数调用
<!DOCTYPE html><html><head> <meta http-equiv="content-type" content="text/html; charset=utf-8" /> <title>js调用</title> <script src="...
2013-09-27 15:35:00
154
转载 Newtonsoft.Json解析json字符串和写json字符串
//using Newtonsoft.Json; StringBuilder sb = new StringBuilder(); string str = "[{ID:'1',Name:'zhangsan',Other:[{Age:'111'}]}]"; JavaScriptArray javascript = (JavaScri...
2013-09-24 10:23:00
197
转载 图片压缩
using System;using System.Collections.Generic;using System.Web;using System.Drawing.Imaging;using System.Drawing;/// <SUMMARY>///MakeThum 的摘要说明/// </SUMMARY>public...
2013-09-17 11:12:00
93
转载 sql去重
select id,OrderID,Mobile,Name from (select id,OrderID,Mobile,Name from V_Order where len(isnull(Mobile,''))>0 and State=0) Customer where id in (select min(id) from (select id,OrderI...
2013-09-12 18:20:00
105
转载 获得用户控件html
public static string getUControlHtml(string controlName) { StringBuilder build = new StringBuilder(); HtmlTextWriter htmlWriter = new HtmlTextWriter(new StringWriter(...
2013-08-16 11:05:00
89
转载 jquery值发生改变时触发
$("#txtId").bind("input propertychange change", function (event) { if (event.type != "propertychange" || event.originalEvent.propertyName == "value") { $(t...
2013-06-14 11:18:00
407
转载 后台转成json数据
CommonJsonModelAnalyzer.csusing System;using System.Collections.Generic;using System.Linq;using System.Text;namespace ConvertJosn{ public class CommonJsonModelAnalyzer {...
2013-06-07 21:04:00
84
转载 委托
public delegate void MyDelegate(object sender, EventArgs e); protected void Page_Load(object sender, EventArgs e) { MyDelegate md = new MyDelegate(Button1_Click); ...
2013-06-07 20:50:00
69
转载 谷歌地图测试
<!DOCTYPE html><html><head> <title>Simple Map</title> <meta name="viewport" content="initial-scale=1.0, user-scalable=no"> <meta chars...
2013-05-30 13:26:00
174
转载 连续每天的数据
IF OBJECT_ID('tempdb..#t') IS NOT NULL DROP TABLE #t;create table #t(id int identity,Dt varchar(10));declare @starttime datetime,@endtime datetimeset @starttime = '===start==='set...
2013-05-14 11:23:00
64
转载 正则获取图片路径
protected StringBuilder sb = new StringBuilder(); protected void Page_Load(object sender, EventArgs e) { string str = QConnectSDK.CustomWebRequest.getResponse("/", QConnectSD...
2013-04-27 16:07:00
194
转载 图片延迟加载
<script src="js/jquery-1.7.2.min.js" type="text/javascript"></script> <script type="text/javascript"> (function ($) { $.extend($.fn, {...
2013-04-27 16:03:00
64
转载 jsonsql
/** JsonSQL var _f1_obj = jsonsql.query("select id,mc,fid from json where (fid==475 && id==875 || fid==475)", json);*/var jsonsql = { query: function (sql, json) { ...
2013-04-11 17:37:00
79
转载 table树
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head>&...
2013-03-24 15:23:00
87
转载 jquery无限级联数据
(function ($) { $.extend($.fn, { lSelect: function (options) { // 默认参数 var settings = { url: "", // 数据获取url parameter...
2013-03-24 15:20:00
140
转载 jquery日期级联插件
<html><head><title> 年月日三下拉框联动 </title> <script src="jquery-1.7.2.min.js" type="text/javascript"></script> <script type="text/javascript">...
2013-03-24 14:56:00
120
转载 select获取及选中
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head>...
2012-12-19 10:14:00
72
转载 防盗代码
Uri u = context.Request.UrlReferrer;//访问来源地址string ip = context.Request.UserHostAddress;//访问来源IPstring serverHost = context.Request.Url.Host;//当前访问主机地址 string localIP=System....
2012-12-11 21:18:00
330
转载 sqlserver区分大小写
CREATE FUNCTION StrComp(@Str1 VARCHAR(50),@Str2 VARCHAR(50))RETURNS INTEGERASBEGINDECLARE @i INTEGERDECLARE @y INTSET @i=0SET @y=1DECLARE @iLen INTSET @iLen = LEN(LTRIM(RTRIM(...
2012-12-10 10:53:00
154
转载 数据采集类
using System;using System.Collections.Generic;using System.Text;using System.Net;using System.Net.Security;using System.Security.Cryptography.X509Certificates;using System.IO;usin...
2012-12-08 19:45:00
89
转载 层首屏居中
<div style="position:absolute; width:740px; height:340px; left:50%; top:50%; margin:-170px 0 0 -370px; background:#f00;"></div>转载于:https://www.cnblogs.com/daixingqing/archive...
2012-12-08 16:13:00
64
转载 清除浮动
.clearfix:after{visibility:hidden;display:block;font-size:0;content:"\20";clear:both;height:0;}* html .clearfix{zoom:1;}/* IE6 */.clear{ clear:both;}:first-child+html .clearfix{zoom:1;}/*...
2012-12-08 16:04:00
49
转载 图片垂直剧中
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head>...
2012-11-15 05:13:00
92
转载 对联广告
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head>...
2012-11-14 10:29:00
69
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人