摘要:-------还原数据库RESTORE DATABASE [" + 新数据库名 + "] FROM DISK = N'" + 备份文件路径+ "' WITH FILE = 1, NOUNLOAD , STATS = 10, RECOVERY , MOVE N'" + Data文件名 + "' TO N'" + 存放DATA文件的绝对路径+ "', MOVE N'" + Log文件名 ...
阅读全文
摘要:Dim openFileDialog_ScriptFile As New System.Windows.Forms.OpenFileDialog '通用对话框,选择文件 If openFileDialog_ScriptFile.ShowDialog() = DialogResult.OK Then 'DialogResult.OK 确定 ...
阅读全文
摘要:Try Dim root As DirectoryEntry = New DirectoryEntry("IIS://localhost/W3SVC") Dim siteID As Integer = 1 Dim e As New DirectoryEntry For Each e In root.Chil...
阅读全文
摘要:For Each Node In XmlDocument.Item("configuration").Item("appSettings") If Node.Name = "add" Then If Node.Attributes.GetNamedItem("key").Value = "SQLConnString" Then ...
阅读全文
摘要:Dim regist As RegistryKey = Registry.LocalMachine Dim reg As RegistryKey Dim regkey As String = "SOFTWARE" reg = regist.OpenSubKey(regkey, True) reg.CreateSubKey("TCKJ")...
阅读全文
摘要:Public Sub ShowMyDialogBox() Dim testDialog As New Form2() ' Show testDialog as a modal dialog and determine if DialogResult = OK. If testDialog.ShowDialog(Me) = System.Windows.Forms.Dial...
阅读全文
摘要:(转:http://chinapcc1978.spaces.live.com/PersonalSpace.aspx?_c02_owner=1) 你让我痛快,我才让你爽! 我去换50张20的人民币,用来发小红包。 于是拿了1000去银行换,那小子态度极其不好的说“没有,不能换给你”呵!态度实在恶劣啊。 我十分凶恶的反问“你再说一次” 那...
阅读全文
摘要:(转...) C#操作注册表 以下从‘读’‘写’‘删除’‘判断’四个事例实现对注册表的简单操作 1.读取指定名称的注册表的值 程序代码private string GetRegistData(string name) { string registData; RegistryKey hkml = Registry.LocalMachine; RegistryKey software = hkm...
阅读全文