就是博客
If you think you can, you can!
摘要: DECLARE @Path nvarchar(260)SET @Path = 'E:\study\SQL'IF RIGHT(@Path, 1) '\'SET @Path = @Path + '\'IF OBJECT_ID('tempdb..#') IS NOT NULLDROP TABLE #CREATE TABLE #(id int IDENTITY,directory nvarchar(260),depth int,IsFile bit)INSERT # EXEC master.dbo.xp_dirtree@path = @path,@depth = 0,@file = 1DECLA 阅读全文
posted @ 2010-12-17 11:00 sungcong 阅读(766) 评论(0) 推荐(0) 编辑
摘要: using System.Net;using System.IO;using System.Text; //方法一: // Create a request for the URL. WebRequest request = WebRequest.Create("http://www.hao123.com"); // If required by the server, set the credentials. request.Credentials = CredentialCache.DefaultCredentials; // Get the response. HttpWebRespon 阅读全文
posted @ 2010-12-17 10:58 sungcong 阅读(248) 评论(0) 推荐(0) 编辑
摘要: using Microsoft.Win32;public static void RunWhenStart(bool Started, string name, string path) { RegistryKey HKLM = Registry.LocalMachine; RegistryKey Run = HKLM.CreateSubKey(@"SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Run\"); if (Started == true) { try { Run.SetValue(name, path); HKLM.Close(); } 阅读全文
posted @ 2010-12-17 10:58 sungcong 阅读(264) 评论(0) 推荐(0) 编辑
摘要: 在运行WebService的网站中找到web.config并修改此文件:1)找到节点system.web/system.web2)在此节点里加入以下设置: webServices protocols add name="HttpPost" / add name="HttpGet" / /protocols /webServices 阅读全文
posted @ 2010-12-17 10:54 sungcong 阅读(873) 评论(0) 推荐(0) 编辑
摘要: 在 Visual Studio 和 .NET Framework 中有三种计时器控件:基于服务器的计时器(可以在“工具箱”的“组件”选项卡上看到)、基于 Windows 的标准计时器(可以在“工具箱”的“Windows 窗体”选项卡上看到)和线程计时器(只能以编程方式使用)。基于 Windows 的计时器从 Visual Basic 1.0 版起就存在于该产品中,并且基本上未做改动。该计时器针对在 Windows 窗体应用程序中使用而进行了优化。基于服务器的计时器是传统的计时器为了在服务器环境上运行而优化后的更新版本。线程计时器是一种简单的、轻量级计时器,它使用回调方法而不是使用事件,并由线程 阅读全文
posted @ 2010-12-17 10:50 sungcong 阅读(456) 评论(0) 推荐(0) 编辑