Esempio n. 1
0
        private void Initialize()
        {
            try
            {
                group = new BTSS.Logic.Group(Common.Core.ConnectionString);
                validation = new BTSS.Common.Validation(); 
                validation.Validate(this);

                InitializeGrid();

                if (Operation == Common.Core.Operation.UPDATE || Operation == Common.Core.Operation.VIEW)
                {

                    Logic.GetGroupDetailsResult result = group.GetGroupDetails(GroupId);

                    textBoxID.Text = GroupId;
                    textBoxName.Text = result.Name;
                    textBoxDescription.Text = result.Desc;

                    if (Operation == Common.Core.Operation.VIEW)
                    {
                        userControlButtonsSave.Visible = false;
                        Lock();
                    }
                } 
                
                LoadModules();
                textBoxName.Focus();
            }
            catch (Exception)
            {
                throw;
            }
        }
Esempio n. 2
0
        private void Initialize()
        {
            try
            {
                group = new Logic.Projects.Group(Common.Core.ProjectConnectionString, Common.Core.ProjectDataProvider);
                validation = new BTSS.Common.Validation(); 
                validation.Validate(this);

                InitializeGrid();

                if (Operation == Common.Core.Operation.UPDATE || Operation == Common.Core.Operation.VIEW)
                {
                                                            
                    DataRow dr;

                    dr = group.GetGroupDetails(GroupId);

                    textBoxID.Text = GroupId;
                    textBoxGroupName.Text = dr["grp_name"].ToString();
                    textBoxGroupName.Tag = dr["grp_name"].ToString();
                    textBoxDescription.Text = dr["grp_desc"].ToString();

                    if (Operation == Common.Core.Operation.VIEW)
                    {
                        userControlButtonsSave.Visible = false;
                        Lock();
                    } 
                }

                LoadModuleAccess();
                textBoxGroupName.Focus();
            }
            catch (Exception)
            {
                throw;
            }
        }
Esempio n. 3
0
        private void Initialize()
        {
            try
            {
                module = new BTSS.Logic.Projects.Module(Common.Core.ProjectConnectionString, Common.Core.ProjectDataProvider);
                validation = new BTSS.Common.Validation(); 
                validation.Validate(this);

                if (Operation == Common.Core.Operation.UPDATE || Operation == Common.Core.Operation.VIEW)
                {                     
                    DataRow dr;

                    dr = module.GetProjectModuleDetails(ModuleId);

                    textBoxID.Text = ModuleId;
                    textBoxModuleName.Text = dr["mod_name"].ToString();
                    textBoxModuleName.Tag = dr["mod_name"].ToString();
                    textBoxDescription.Text = dr["mod_desc"].ToString();
                          
                    if (Operation == BTSS.Common.Core.Operation.VIEW)
                    {
                        userControlButtonsSave.Visible = false;
                        Lock();
                    }
                }

                InitializeGrid();

                if (Common.Core.ProjectDataProvider == BTSS.Common.Core.DataProvider.SQL) LoadTables();
                textBoxModuleName.Focus();

            }
            catch (Exception)
            {
                throw;
            }
        }
Esempio n. 4
0
 private void Initialize()
 {
     try
     {
         group = new Logic.Projects.Group(Common.Core.ProjectConnectionString, Common.Core.ProjectDataProvider);
         validation = new BTSS.Common.Validation(); 
         validation.Validate(this);
         SetControlListingAccessRights();
     }
     catch (Exception)
     {
         throw;
     }        
 }
Esempio n. 5
0
    private void Initialize()
    {
        try
        {
            user = new User(Core.ConnectionString);
            Validation = new Validation();
            timerConnected = new Timer();
            timerConnected.Tick += new EventHandler(TimerConnected_Ticks);
            
            Validation.Validate(this);
            toolStripStatusLabelUserName.Text = "User: "******"Refresh Database List");
            toolTipMain.SetToolTip(buttonConnect, "Connect to Database");

            SetAccessRights();

            StringBuilder sb = new StringBuilder();
            Text = sb.Append(Text).Append(" ").Append(Application.ProductVersion).ToString();          
        }
        catch (Exception)
        {
            throw;
        }
    }
Esempio n. 6
0
        private void Initialize()
        {
            try
            {
                user = new BTSS.Logic.User(Common.Core.ConnectionString);
                validation = new BTSS.Common.Validation(); 
                validation.Validate(this); 

                if (Operation == Common.Core.Operation.UPDATE || Operation == Common.Core.Operation.VIEW)
                {
                    Logic.GetUserDetailsResult result = user.GetUserDetails(UserId);

                    textBoxID.Text = UserId;
                    textBoxID.Tag = UserId;
                     
                    textBoxLastName.Text = result.LastName;
                    textBoxLastName.Tag = result.LastName;

                    textBoxFirstName.Text = result.FirstName;
                    textBoxFirstName.Tag = result.FirstName;

                    textBoxMI.Text = result.MiddleName;
                    textBoxMI.Tag = result.MiddleName;

                    textBoxUserName.Text = result.UserName;
                    textBoxUserName.Tag = result.UserName;
                     
                    LoadProjects();
                    LoadGroups();
                   
                    if (Operation == Common.Core.Operation.VIEW)
                    {
                        userControlButtonsSave.Visible = false;
                        Lock();
                    } 
                }
                 
                textBoxLastName.Focus();

            }
            catch (Exception)
            {
                throw;
            }
        }
Esempio n. 7
0
        private void Initialize()
        {
            try
            {
                project = new BTSS.Logic.Project(Common.Core.ConnectionString);
                Validation = new BTSS.Common.Validation();
                Validation.Validate(this);
 
                if (Operation == Common.Core.Operation.INSERT)
                { 
                    radioButtonMSAccess.Checked = true; 
                }
                else if (Operation == Common.Core.Operation.UPDATE || Operation == Common.Core.Operation.VIEW)
                { 
                    Logic.GetProjectDetailsResult result = project.GetProjectDetails(ProjectId);

                    textBoxID.Text = ProjectId;
                    textBoxName.Text = result.Name;
                    textBoxDesription.Text = result.Desc;
                    checkBoxIsActive.Checked = result.IsActive.Value;
                    textBoxVersion.Text = result.Version;
                    textBoxSharepointURL.Text = result.SharepointURL;
                    textBoxErrorLogPath.Text = result.PathErrorLog;
                    textBoxBusinessOwner.Text = result.BusinessOwner;
                    textBoxTester.Text = result.Tester;
                    textBoxOtherContact.Text = result.OtherContact;
                    checkBoxOtherDetails.Checked = result.HasOtherDetails.Value;

                    textBoxSQLDatasource.Text = result.Datasource;
                    textBoxSQLDatabaseName.Text = result.DatabaseName;
                    textBoxSQLUserId.Text = result.UserID;
                    textBoxSQLPassword.Text = result.Password;
                    textBoxFileMDB.Text = result.File;
                    checkBoxAllowDevelopmentMode.Checked = result.EnableBypassKey.Value;
                    checkBoxAllowDevelopmentMode.Tag = result.EnableBypassKey.Value;
                    textBoxFileMDW.Text = result.MDW;
                    textBoxAccessUserID.Text = result.UserID;
                    textBoxAccessPassword.Text = result.Password;

                    if (result.Provider == "OLEDB")
                    {
                        radioButtonMSAccess.Checked = true;
                    }
                    else //sql
                    {
                        radioButtonSQL.Checked = true;
                    }

                    if (Operation == Common.Core.Operation.VIEW)
                    {
                        userControlButtonsSave.Visible = false;
                        Lock();
                    }
                }

                textBoxName.Focus();
            }
            catch (Exception)
            {
                throw;
            }
        }
Esempio n. 8
0
 private void Initialize()
 {
     try
     {
         user = new BTSS.Logic.User(Common.Core.ConnectionString);
         validation = new BTSS.Common.Validation(); 
         validation.Validate(this);
         SetControlListingAccessRights();
     }
     catch (Exception)
     {
         throw;
     }        
 }