KimhillZhang  
上一页 1 2 3 4 5 6 7 8 ··· 16 下一页

2012年12月19日

摘要: 要删除的字符串ID为:string SDSALES_IDString = 1,2,3,4,5,6,7//转成ArrayArray array = SDSALES_IDString.Split(new string[] { "," }, StringSplitOptions.RemoveEmptyEntries).ToArray<string>();在模型定义一个 public ArraySDSALES_IDs {get;set;}XML:<delete id="DeleteManyT_LABEL_SDSALES" parameterCl 阅读全文
posted @ 2012-12-19 20:31 KimhillZhang 阅读(355) 评论(0) 推荐(0)

2012年11月22日

摘要: 今天在winform上需要上传,删除服务器上的文件,网上找了下上传是很多,可删除没有找到答案,,最后只能拿个土办法实现了,这里是用ashx文件来处理上传:B/Spublic void ProcessRequest(HttpContext context) { foreach (string fileKey in context.Request.Files) { try { HttpPostedFile file = context.Request.Files[fileKey]; string oldFileName = file.FileName; //原文件名 xxx.jpg int ex. 阅读全文
posted @ 2012-11-22 17:00 KimhillZhang 阅读(3415) 评论(1) 推荐(0)

2012年11月19日

摘要: 后台从数据库取出时间,JSON格式化后再传到gridpanel,这时时间变成了:/Date(32331121223)/这样的格式,那么这时需要以下处理才可以正常显示:在var record = Ext.data.Record.create([ { name: 'PublicDate', mapping: 'PublicDate', dateFormat: 'Y-m-d', convert: function (v) { if (v == null) { return null; } var d = new Date(); var str = v. 阅读全文
posted @ 2012-11-19 22:17 KimhillZhang 阅读(522) 评论(0) 推荐(0)

2012年11月4日

摘要: 比如一个方法:slideUp(参数,回调函数);由于头脑比较痴呆,所以都搞不明白是怎么写的;今天偶尔看到了,让我明白了。恍然,还挺简单的;例如:window.onload = function(){ test({top:"11px", left:"12px", bottom:"13px"}, function(){ alert("已经执行完成");})}//定义function test(json, callback){ for(j in json){ alert(json[j]); } if(callback){ 阅读全文
posted @ 2012-11-04 11:12 KimhillZhang 阅读(304) 评论(1) 推荐(0)
 
摘要: 看以with用法,感觉很实用,就蛮写了下;with:为一个或一组 属性或方法 指定默认对象形式:with(对象){ 单写属性或方法}例:var test = function(){ this.str1 = "width test1"; this.str2 = "width test2";//这里需使用this};test.prototype.method = function(){ alert("method");}window.onload = function(){ var t = new test(); alert(t.str1 阅读全文
posted @ 2012-11-04 10:40 KimhillZhang 阅读(343) 评论(1) 推荐(0)

2012年10月11日

摘要: MatrixTransform的六个点如下图,这是本人的理解,有错误的请高手指明哈。。。实例:<Grid x:Name="LayoutRoot" Background="White"> <Rectangle Width="200" Height="200" Stroke="Black" StrokeThickness="2"> <Rectangle.Fill> <LinearGradientBrush> <Gradient 阅读全文
posted @ 2012-10-11 00:27 KimhillZhang 阅读(409) 评论(1) 推荐(0)

2012年10月10日

摘要: 在注册事件时的另一写法,高手们不需要看滴。。。。。 /// <summary> /// 定义两个委托 /// </summary> public delegate void TestDelegate1(string text); public delegate void TestDelegate2(); /// <summary> /// 定义两个事件 /// </summary> public event TestDelegate1 OnTest1; public event TestDelegate2 OnTest2; public Form 阅读全文
posted @ 2012-10-10 22:13 KimhillZhang 阅读(260) 评论(0) 推荐(1)

2012年10月3日

摘要: 服务端:namespace WcfServiceFist{ [ServiceContract] public interface IServiceFirst { [OperationContract] double GetSum(int x, double y); [OperationContract] int GetX(); } [DataContract] public class CompositeType { [DataMember] public int X { get; set; } [DataMember] public double Y { get; set; } publi. 阅读全文
posted @ 2012-10-03 10:50 KimhillZhang 阅读(470) 评论(0) 推荐(0)

2012年10月2日

摘要: SerialPort()://属性.BaudRate;获取或设置波特率.BytesToRead;得到 接收到数据的字节数.BytesToWrites;得到送往串口的字节数.DataBits;获取或设置数据位.IsOpen;获取一个值,判断串口是否打开.Pariy;获取或设置校验位.PortName;串口名称.ReadBufferSize;获取或设置读取数据的缓存大小.ReadTimeout;读取超时时间.StopBits;停止位.NewLine;用于解释通过ReadLine()与WriteLine()的值.WriteBufferSize;与ReadBufferSize相对.WriteTime. 阅读全文
posted @ 2012-10-02 16:46 KimhillZhang 阅读(1524) 评论(0) 推荐(0)

2012年9月24日

摘要: 先看下图:这个是在DTCMS的基础上实现的,因为分类太多,需要伸缩起来,其实我的这个实例还存在很多问题,在这里只是提供一个思路供大家参考参考。实现的机制就是在每个<tr>标签上添加一些属性,如下:<tr meid="true" id='tr_<%#Eval("Id") %>' style=" cursor:pointer;" children='<%#Eval("Column1") %>' onclick="getChild( 阅读全文
posted @ 2012-09-24 00:09 KimhillZhang 阅读(1516) 评论(1) 推荐(1)
上一页 1 2 3 4 5 6 7 8 ··· 16 下一页