コード例 #1
0
ファイル: MsSqlExtenders.cs プロジェクト: janproch/datadmin
            public void SystemBackup()
            {
                var    dbconn = m_appobj.FindDatabaseConnection();
                var    sconn  = dbconn.Connection.SystemConnection;
                string bakdir = sconn.ExecuteScalar(@"
                    declare @BackupDirectory nvarchar(512);
                    exec master.dbo.xp_instance_regread N'HKEY_LOCAL_MACHINE', N'Software\Microsoft\MSSQLServer\MSSQLServer', N'BackupDirectory', @BackupDirectory OUTPUT;
                    select @BackupDirectory AS [BackupDirectory]").ToString();

                MsSqlBackupDialog.Run(bakdir, dbconn.CloneSource());
            }
コード例 #2
0
        public static void Run(string bakdir, IDatabaseSource db)
        {
            var win = new MsSqlBackupDialog(bakdir, db);

            win.ShowDialogEx();
        }