帮你找了两相关的文档,请看看吧。
http://www.cnblogs.com/wuhuacong/archive/2008/01/21/1047854.html
http://www.cnblogs.com/ZZZDarrick/archive/2011/05/25/2051589.html