上一页 1 2 3 4 5 6 ··· 9 下一页
摘要: DictionaryobjDictionary=newDictionary();objDictionary.Add(1,"张三");objDictionary.Add(2,"李四");objDictionary.Add(3,"王二麻子");objDictionary.Add(4,"小淘气... 阅读全文
posted @ 2015-01-19 14:44 ゞ追忆o0ゞ 阅读(347) 评论(0) 推荐(1) 编辑
摘要: --杀死全部锁死进程ALTERProcSp_KillAllProcessInDB@DbNameVarChar(100)asifdb_id(@DbName)=NullbeginPrint'DataBasedosenotExist'endelseBeginDeclare@spIdVarchar(30)D... 阅读全文
posted @ 2014-07-18 17:37 ゞ追忆o0ゞ 阅读(514) 评论(0) 推荐(0) 编辑
摘要: --本月第一天:selectdateadd(dd,-day(getdate())+1,getdate())--本月最后一天:SELECTdateadd(ms,-3,DATEADD(mm,DATEDIFF(m,0,getdate())+1,0))--上个月第一天:select CONVERT(int,... 阅读全文
posted @ 2014-07-09 19:39 ゞ追忆o0ゞ 阅读(33764) 评论(2) 推荐(0) 编辑
摘要: 原文地址:http://www.cppblog.com/liquidx/archive/2009/06/23/88366.html译者:gashero目录1概览1.1什么是protocol buffer1.2他们如何工作1.3为什么不用XML?1.4听起来像是为我的解决方案,如何开始?1.5一点历史... 阅读全文
posted @ 2014-06-27 10:10 ゞ追忆o0ゞ 阅读(342) 评论(0) 推荐(0) 编辑
摘要: /*html5doctor.comResetStylesheetv1.6.1LastUpdated:2010-09-17Author:RichardClark-http://richclarkdesign.comTwitter:@rich_clark*/html,body,div,span,obje... 阅读全文
posted @ 2014-05-16 17:18 ゞ追忆o0ゞ 阅读(392) 评论(0) 推荐(0) 编辑
摘要: 原文地址:http://blog.sina.com.cn/s/blog_493cafbb0100qy91.html症状:SQL SERVER2005里面,启动SQL代理服务,启动正常,但是在sql server 代理还是显示已禁用代理 xp在Management Studio中新建维护计划时,提示以下错误信息:“代理XP”组件已作为此服务器安全配置的一部分被关闭。系统管理员可以使用sp_configure来启用“代理XP”。有关启用“代理XP”的详细信息,请参阅SQL Server联机丛书中的“外围应用配置器”。解决方法:Sql代码sp_configure 'show advanced 阅读全文
posted @ 2013-10-28 14:59 ゞ追忆o0ゞ 阅读(387) 评论(0) 推荐(0) 编辑
摘要: //WriteableBitmaptoARGBbytearraypublicstaticbyte[]ToByteArray(thisWriteableBitmapbmp){int[]p=bmp.Pixels;intlen=p.Length*4;byte[]result=newbyte[len];//ARGBBuffer.BlockCopy(p,0,result,0,len);returnresult;}//CopyARGBbytearrayintoWriteableBitmappublicstaticvoidFromByteArray(thisWriteableBitmapbmp,byte[] 阅读全文
posted @ 2013-09-12 21:11 ゞ追忆o0ゞ 阅读(489) 评论(0) 推荐(0) 编辑
摘要: 代码是Java转过来的,变量名都没有改……有空再整理一下好了。publiclongtoDecimal(stringinput,longbs){try{longBigtemp=0,temp=1;intlen=input.Length;for(inti=len-1;i>=0;i--){if(i!=len-1)temp*=bs;longnum=changeDec(input[i]);Bigtemp+=temp*num;}returnBigtemp;}catch{return0;}}//十进制转换中把字符转换为数staticintchangeDec(charch){intnum=0;if(ch& 阅读全文
posted @ 2013-04-19 16:02 ゞ追忆o0ゞ 阅读(3014) 评论(5) 推荐(0) 编辑
摘要: 引入System.Runtime.Serialization.Json命名空间使用 DataContractJsonSerializer类实现序列化序列化类:PeopleCode highlighting produced by Actipro CodeHighlighter (freeware)http://www.CodeHighlighter.com/--> public class People { public int Id { get; set; } public string Name { get; set... 阅读全文
posted @ 2013-04-11 18:14 ゞ追忆o0ゞ 阅读(1488) 评论(0) 推荐(0) 编辑
摘要: public static class ObjectExtension { public static T Convert<T>(this object target) { T result = default(T); if (target != null) { result = (T)System.Convert.ChangeType(target, typeof(T), CultureInfo.InvariantCulture); } ... 阅读全文
posted @ 2013-04-08 10:16 ゞ追忆o0ゞ 阅读(279) 评论(0) 推荐(0) 编辑
摘要: 原贴地址:http://www.soaspx.com/dotnet/csharp/csharp_20110506_7607.htmlCultureInfo简述CultureInfo类位于System.Globalization命名空间内,这个类和这个命名空间许多人都不了解也认为不需要太多了解,实际上,你写的程序中会经常间接得使用这些类。简单的说:当进行数字,日期时间,字符串匹配时,都会进行CultureInfo的处理,也就是不同的CultureInfo下,这些操作的结果可能会不一样。这里要介绍一下非常容易被忽视的InvariantCulture。通过示例了解InvariantCulture前面 阅读全文
posted @ 2013-04-07 23:12 ゞ追忆o0ゞ 阅读(357) 评论(0) 推荐(0) 编辑
摘要: 先来个C#版的: public class DESHelper { /// <summary> /// DES加密算法 /// </summary> /// <param name="encryptString">要加密的字符串</param> /// <param name="sKey">加密码Key</param> /// <returns>正确返回加密后的结果,错误返回源字符串</returns> public static string ToDESEn 阅读全文
posted @ 2013-04-01 12:56 ゞ追忆o0ゞ 阅读(6556) 评论(1) 推荐(1) 编辑
摘要: using System;using System.Collections.Generic;using System.Text;using System.Runtime.InteropServices; //这个肯定要的 namespace WindowsApplication1{ class win32API { public const int OPEN_PROCESS_ALL = 2035711; public const int PAGE_READWRITE = 4; public const int PROCESS_CREAT... 阅读全文
posted @ 2013-03-19 21:45 ゞ追忆o0ゞ 阅读(471) 评论(0) 推荐(0) 编辑
摘要: 原贴地址:http://www.cnblogs.com/zhongweiv/archive/2011/11/11/IEqualityComparer.html写这个源于CSDN一位网友的提问题目:下列数据放在一个List中,当ID和Name都相同时,去掉重复数据ID Name 1 张三 1 李三 1 小伟 1 李三 2 李四 2 李武------------------------------------------------------------------------------------------------------------解决这个问题,方法很多,最开始想到的就Enum. 阅读全文
posted @ 2013-02-19 12:48 ゞ追忆o0ゞ 阅读(302) 评论(0) 推荐(0) 编辑
摘要: 乱码部分请参考:http://blog.csdn.net/icephone/article/details/8217567一、安装sudo add-apt-repository ppa:webupd8team/sublime-text-2sudo apt-get updatesudo apt-get install sublime-text-2二、破解首先查看一下sublime-text 2安装路径,然后用vim打开sublime_text文件# whereis sublime-text-2输出结果:# sublime-text-2:/usr/bin/sublime-text-2 /usr/. 阅读全文
posted @ 2013-01-12 17:06 ゞ追忆o0ゞ 阅读(2485) 评论(1) 推荐(0) 编辑
摘要: 系统:CentOS 6.3错误信息:source='pcrecpp.cc' object='pcrecpp.lo' libtool=yes \ DEPDIR=.deps depmode=none /bin/sh ./depcomp \ /bin/sh ./libtool --tag=CXX --mode=compile -DHAVE_CONFIG_H -I. -c -o pcrecpp.lo pcrecpp.cclibtool: compile: unrecognized option `-DHAVE_CONFIG_H'libtool: compile: 阅读全文
posted @ 2013-01-10 20:19 ゞ追忆o0ゞ 阅读(2169) 评论(0) 推荐(0) 编辑
摘要: 因为是centos linux,默认可以采用yum方式安装,则采用如下命令安装gcc编译器即可:# yum -y install gcc安装更新了如下几个组件:gcc 4.1.2-44.el5binutils 2.17.50.0.6-9.el5cpp 4.1.2-44.el5glibc-devel 2.5-34.el5_3.1glibc-headers 2.5-34.el5_3.1kernel-headers 2.6.18-164.el5libgomp 4.3.2-7.el5 阅读全文
posted @ 2013-01-10 14:50 ゞ追忆o0ゞ 阅读(452) 评论(0) 推荐(0) 编辑
摘要: 原贴地址:http://www.soaspx.com/dotnet/service/service_20120720_9432.html问题如下图:网上有关于这个处理办法,说道:VS2010在更新了SP1后,会在开机时自动启动一个服务,占用WAMP的80端口,导致WAMP无法正常启动Apache。提示信息:Your port 80 is actually used by :Server: Microsoft-HTTPAPI/2.0Press Enter to exit...解决办法如下: 1. 进入控制面板→管理工具→服务。 2. 停止[Web 部署代理服务],并设置为手动或禁用状态,以防止下 阅读全文
posted @ 2012-12-28 10:42 ゞ追忆o0ゞ 阅读(1876) 评论(0) 推荐(1) 编辑
摘要: 原文地址:http://lxflfr.blog.163.com/blog/static/129119579200983004539908/zlib 是通用的压缩库,提供了一套 in-memory 压缩和解压函数,并能检测解压出来的数据的完整性(integrity)。zlib 也支持读写 gzip (.gz) 格式的文件。下面介绍两个最有用的函数——compress和uncompress。int compress(Bytef *dest, uLongf *destLen, const Bytef *source, uLong sourceLen);compress函数将source缓冲区中的内容 阅读全文
posted @ 2012-12-09 19:36 ゞ追忆o0ゞ 阅读(1171) 评论(0) 推荐(0) 编辑
摘要: usingSystem;usingSystem.Drawing;usingSystem.Drawing.Drawing2D;usingSystem.Drawing.Imaging;usingSystem.IO;usingSystem.Text;usingSystem.Web;namespaceWanJia.CommonUtility{///<summary>///VerifyCode///</summary>publicclassVerifyCode{#regionPrivateField&PublicProperty//随机种子privateRandomobj 阅读全文
posted @ 2012-11-22 17:39 ゞ追忆o0ゞ 阅读(782) 评论(0) 推荐(1) 编辑
上一页 1 2 3 4 5 6 ··· 9 下一页