예제 #1
0
        public void createRecoveryPoint()
        {
            Program.dbHafsjoldData   = null;
            Program.memAktivRegnskab = null;
            Program.karRegnskab      = null;
            Program.karStatus        = null;
            Program.karKladde        = null;

            // unlock lock summasummarum kontoplan
            Program.filestream_to_lock_summasummarum_kontoplan.Close();
            Program.filestream_to_lock_summasummarum_kontoplan = null;

            // open recoverypoint database
            string dbRecovery3060path = m_EksportmappePath + @"dbRecoveryHafsjoldData.sdf";

            m_dbRecovery = new DbRecoveryHafsjoldData(m_EksportmappePath + @"dbRecoveryHafsjoldData.sdf");
            if (!File.Exists(dbRecovery3060path))
            {
                m_dbRecovery.CreateDatabase();
            }

            // create recoverypoint
            TblRecoveryPoint rec_RceoveryPoint = setupRecoveryPoint();

            createRecoveryPoint(rec_RceoveryPoint);

            // lock lock summasummarum kontoplan
            Program.filestream_to_lock_summasummarum_kontoplan = new FileStream(Program.path_to_lock_summasummarum_kontoplan, FileMode.Open, FileAccess.Read, FileShare.None);
        }
예제 #2
0
        public void TestRecovery()
        {
            m_dbRecovery = new DbRecoveryHafsjoldData(@"C:\Documents and Settings\mha\Dokumenter\SummaSummarum\dbRecoveryHafsjoldData.sdf");
            //m_dbRecovery.CreateDatabase();
            //TblRecoveryPoint rec_RceoveryPoint = setupRecoveryPoint();
            //createRecoveryPoint(rec_RceoveryPoint);

            //TblRecoveryPoint rec_RestorePoint = setupRestorePoint();
            //restoreRecoveryPoint(rec_RestorePoint);

            //deleteContentNotUsed();
        }