摘要: 我的前面一篇文章提到了如何在使用了ASP.NET form authentication的二级站点之间共享登陆状态, http://www.cnblogs.com/jzywh/archive/2007/09/23/902905.html, 今天, 我要写的是如何在二级域名站点之间,主站点和二级域名站点之间共享Session。 阅读全文
posted @ 2008-11-02 14:17 江大渔 阅读(9381) 评论(31) 推荐(1) 编辑
摘要: 博客园已有几位同学发表了关于FileSystemWatcher事件多次触发的解决方法的文章,很好地解决了事件多次激发的问题。 主要方法有: 1.延迟激发法。 http://www.cnblogs.com/dragon/archive/2008/07/04/filesystemwatcher.html 原理是延迟调用事件的代理,将多次事件合并为一次,从而很好的解决了此问题,唯一的缺憾是时间激发不及时,不适用于实时性较高的系统。 2.临时禁用法. 3.检查最后更新时间法. 阅读全文
posted @ 2008-07-23 21:55 江大渔 阅读(8457) 评论(6) 推荐(1) 编辑
摘要: 可在windows server 2003 or windows server 2008 下直接下载安装 下载页面: http://windowslivewriter.spaces.live.com/blog/cns!D85741BB5E0BE8AA!1508.entry 直接下载地址: http://download.microsoft.com/download/8/0/9/809604cd-bd08-42c8-b590-49c332059e64/writer.msi 阅读全文
posted @ 2008-07-23 07:28 江大渔 阅读(1513) 评论(3) 推荐(0) 编辑
摘要: The class System.Convert provide two basic methods "ToBase64String()" and "Convert.FromBase64String()" to encode a byte array to a base64 string and decode a base64 string to a byte array. It is very good to use them to encode and decode base64. But in some case, it is a disaster. For example, if you want to encode a 4 gb file to base64, the code above must throw an OutOfMemory exception., because you must read the file into a byte array. So we need to look for another way to e 阅读全文
posted @ 2008-04-20 21:48 江大渔 阅读(2286) 评论(1) 推荐(0) 编辑
摘要: 很多人用ActionlessForm来解决这个问题,可是把每个form都改成ActionlessForm的工作量确实太大。 如果你的系统中已定义了叶面基类,那么问题可就简单的多了: protected override void OnLoadComplete(EventArgs e) { string originalUrl = Context.Items["OriginalUrl"] as string; if (!string.IsNullOrEmpty(originalUrl)) //So this page have been urlrewriten, after the page onloaded, rewrite the url of this page to original url { string query = string.Empty; int pos = originalUrl.IndexOf('?'); 阅读全文
posted @ 2007-12-20 13:36 江大渔 阅读(2326) 评论(5) 推荐(0) 编辑
摘要: Flex第一步 -- 国内第一本关于Flex的书籍 《flex第一步》 全书共分为17章。内容包括:Flex简介、Flex的安装和开发环境的建立、MXML 语法简介、使用容器控制界面布局、使用组件处理数据和交互、使用行为对象和动画效果、ActionScript 3.0编程知识、Flex的事件机制、数据绑定、组件的使用、Flex 2.0新特性实例开发、Flex与外部的数据通信、Flex程序设计等。 书中包括四个大型应用开发实例:Flex数据库留言本、Flex产品展示系统、Flex投票系统、Flex天气预报系统。除此之外,书中还贯穿了大量Demo级小例子,让技术不再抽象,帮你快速掌握Flex开发的关键。 作者深入浅出,从理论到实践,从基础知识到实践项目把Flex的技术阐述得相当到位,堪称国内Flex图书的开山之作。 阅读全文
posted @ 2007-11-22 12:52 江大渔 阅读(706) 评论(1) 推荐(0) 编辑
摘要: 在asp.net 1.1中, 二级域名Forms验证模式下共享登陆状态的方法请参考下面文章: http://www.cnblogs.com/caomao/archive/2005/07/05/186606.html 而在asp.net 2.0中实现方法更为简单,只需修改web.config文件即可,修改方法如下 阅读全文
posted @ 2007-09-23 00:04 江大渔 阅读(4470) 评论(15) 推荐(1) 编辑
摘要: 在.net 1.1中我们要实现压缩这一功能,一般都是用open source的SharpZipLib 或者调用J#类库。 现在在.net 2.0中增加了压缩功能,名字空间为 using System.IO.Compression; 阅读全文
posted @ 2006-05-23 16:23 江大渔 阅读(1270) 评论(0) 推荐(0) 编辑
摘要: 本文背景: http://jzywh.cnblogs.com/archive/2005/09/29/246650.html 网上很多朋友看到我这篇文章,按照我的方法做了,但是还是没有得到想要的效果,其实有些问题需要注意一下,我上篇文章也只是提出了解决这一问题的办法的最核心的内容,有些朋友可能在实际运用中可能会碰到一些问题其实可以根据自己的经验作出相应处理应该可以解决,我在这里帮大家列出几点以帮助大家快速解决问题。 阅读全文
posted @ 2006-02-20 13:29 江大渔 阅读(20466) 评论(52) 推荐(0) 编辑
摘要: a good article:http://www.devx.com/wireless/Article/22552/1954?pf=true微软官方站点 http://www.asp.net/default.aspx?tabindex=4&tabid=44Mobile Application Development Toolkithttp://www.microsoft.com/downloa... 阅读全文
posted @ 2005-12-17 12:37 江大渔 阅读(705) 评论(0) 推荐(0) 编辑
摘要: 1cint(word) then 9 IntIndex = Instr(start+len(ArrWord(word)),StrObj,ArrWord(i))10 if IntIndex>0 then11 flag = flag + 112 'response.writ... 阅读全文
posted @ 2005-10-26 09:55 江大渔 阅读(1071) 评论(0) 推荐(0) 编辑
摘要: 大家应该知道,微软的URLRewrite能够对URL进行重写,但是也只能对域名之后的部分进行重写,而不能对域名进行重写,如:可将 http://www.abc.com/1234/ 重写为 http://www.abc.com/show.aspx?id=1234 但不能将 http://1234.abc.com 重写为 http://www.abc.com/show.aspx?id=1234。 要实现这个功能,前提条件就是 www.abc.com 是泛解析的,再就是要修改一下URLRewriter了。 总共要修改2个文件 阅读全文
posted @ 2005-09-29 14:08 江大渔 阅读(31717) 评论(59) 推荐(4) 编辑
摘要: 很多人都用网上流传的chs2py类进行汉字到拼音的转化,但是这个类存在一点小问题,就是如果 要转化的字符串中含有非中文字符的话就会出错。 所以我就在chs2py类字符转拼音之前先判断字符是否为汉字,如果为汉字就进行转化,否则不转化,直接附加! 阅读全文
posted @ 2005-09-05 11:00 江大渔 阅读(1836) 评论(3) 推荐(0) 编辑
摘要: 样式如下图! 这种带三态复选框的TreeView可以显示出 下级节点是否全部选中,是否有选中,在很多应用程序的开发中都可能会用到! 代码如下: // ---------------------------------------------------------------------------------------------// Copyright (c) 2004... 阅读全文
posted @ 2005-08-25 12:42 江大渔 阅读(2322) 评论(1) 推荐(0) 编辑
摘要: 今天试探性的打开了66.178.223.73的VS2005,添加了个Form和几个控件,里面的代码让我有点郁闷 Form1.cs里面基本没有什么代码 Using directives#region Using directives using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.Windows.Forms; #endregion namespace WindowsApplication3 { partial class Form1 : Form { public Form1() { InitializeComponent(); 阅读全文
posted @ 2005-08-25 11:44 江大渔 阅读(870) 评论(2) 推荐(0) 编辑