示例#1
0
        public bool attachDb()
        {
            try
            {
                SqlServerInstance.Server.AttachDatabase(
                    code, new StringCollection
                {
                    PathDb
                }, AttachOptions.RebuildLog);

                setState();
            }
            catch (Exception e)
            {
                this.validation = new ValidateMdf();
                this.validation.listErrors.Add("AE");
                this.validation.isValid = false;
            }

            return(isAttached);
        }
示例#2
0
 public void validateDb()
 {
     validation = new ValidateMdf(this);
 }
示例#3
0
        public bool attachDb()
        {
            try
            {
                SqlServerInstance.Server.AttachDatabase(
                 code, new StringCollection
                        {
                            PathDb
                        }, AttachOptions.RebuildLog);

                setState();
            }
            catch (Exception e)
            {
                this.validation = new ValidateMdf();
                this.validation.listErrors.Add("AE");
                this.validation.isValid = false;
            }

            return isAttached;
        }
示例#4
0
 public void validateDb()
 {
     validation = new ValidateMdf(this);
 }