protected override void InitalizePage() { _parentForm = (FrmWizard)ParentForm; _parentForm.Text = this.StepDescription; _parentForm.Controls["btnFinish"].Enabled = false; _parentForm.Controls["btnNewSession"].Enabled = true; _lastText = string.Empty; txtLog.Text = string.Empty; _executionTimer.Interval = 3000; _executionTimer.Start(); }
protected override void InitalizePage() { _parentForm = (FrmWizard)ParentForm; _parentForm.Text = this.StepDescription; _parentForm.Controls["btnNewSession"].Visible = true; _parentForm.Controls["btnNewSession"].Enabled = true; stepReadyTimer.Interval = 9000;; stepReadyTimer.Start(); FillPageValues(); }
static void Main() { Application.EnableVisualStyles(); Application.SetCompatibleTextRenderingDefault(false); FrmWizard frmWizard = new FrmWizard(); frmWizard.AddPage(new StartPage()); frmWizard.AddPage(new CreateAccount()); frmWizard.AddPage(new ActiveDirectoryStep()); frmWizard.AddPage(new CreateNewRole()); frmWizard.AddPage(new CreateNewCube()); frmWizard.AddPage(new Summary()); frmWizard.AddPage(new ExecutePage()); Application.Run(frmWizard); }
private void fillIDS() { if (cmbWizardType.SelectedValue.ToString() == addNewAccount) { using (SqlConnection sqlConnection = new SqlConnection(FrmWizard.GetFromWizardSettings("OLTP.Connection.string"))) { sqlConnection.Open(); using (SqlCommand sqlCommand = new SqlCommand("SELECT (MAX(Account_ID)+1) FROM User_GUI_Account", sqlConnection)) { txtAccountID.Text = sqlCommand.ExecuteScalar().ToString(); } } FillClientID(int.Parse(txtAccountID.Text)); FillScopeID(int.Parse(txtAccountID.Text)); } }
protected override void InitalizePage() { _parentForm = (FrmWizard)ParentForm; _parentForm.Text = this.StepDescription; StringBuilder stringBuilder = new StringBuilder(); stringBuilder.AppendLine(((FrmWizard)Parent.Parent).StrSummary); stringBuilder.AppendLine("\n Collected Data:\n"); foreach (KeyValuePair <string, object> item in FrmWizard.AllCollectedValues) { stringBuilder.AppendLine(string.Format("Key: {0} : Value: {1}", item.Key, item.Value)); } txtSummary.Text = stringBuilder.ToString(); stepReadyTimer.Interval = 6000; stepReadyTimer.Start(); }
protected override void InitalizePage() { _parentForm = (FrmWizard)ParentForm; _parentForm.Text = this.StepDescription; if (((bool)FrmWizard.AllCollectedValues["AccountSettings.UseExistingRole"]) == true) { grpRole.Enabled = false; } else { grpRole.Enabled = true; txtRoleMemberName.Text = string.Format(@"EDGE\{0}", FrmWizard.AllCollectedValues["AccountSettings.BI_Scope_Name"]); txtRoleName.Text = string.Format(@"UDM {0}", FrmWizard.AllCollectedValues["AccountSettings.BI_Scope_Name"]); txtRoleID.Text = string.Format("Role {0}", FrmWizard.AllCollectedValues["AccountSettings.BI_Scope_ID"]); } stepReadyTimer.Interval = interval; stepReadyTimer.Start(); }
protected override void InitalizePage() { _parentForm = (FrmWizard)ParentForm; _parentForm.Text = this.StepDescription; if (!(bool)FrmWizard.AllCollectedValues["AccountSettings.UseExistingRole"]) { grpActiveDirectory.Enabled = true; txtUserName.Text = FrmWizard.AllCollectedValues["AccountSettings.BI_Scope_Name"].ToString(); txtFullName.Text = FrmWizard.AllCollectedValues["AccountSettings.BI_Scope_Name"].ToString(); txtPassword.Text = password; } else { grpActiveDirectory.Enabled = false; } stepReadyTimer.Interval = interval; stepReadyTimer.Start(); }
private void FillCPAReplaceComboBox() { cmbCpaReplaceTo.DataSource = null; List <string> comboValues = new List <string>(); //Load default values from app.config string[] googleDefaultValues = FrmWizard.GetFromWizardSettings("EdgeBI.Wizards.GoogleConversions").Split(','); foreach (string str in googleDefaultValues) { string itemReplaced = str; foreach (ListViewItem item in listViewBeData.Items) { if (item.Text == str) { itemReplaced = item.SubItems[1].Text; break; } } comboValues.Add(itemReplaced); } foreach (ListViewItem item in listViewBeData.Items) { if (item.SubItems[0].Text.StartsWith("BO Client Specific")) { comboValues.Add(item.SubItems[1].Text.Trim()); } } cmbCpaReplaceTo.DataSource = comboValues; //cmbBeData.ValueMember = "Key"; //cmbBeData.DisplayMember = "Value"; //cmbCPA.DataSource = _CPAData.ToList(); //cmbCPA.ValueMember = "Key"; //cmbCPA.DisplayMember = "Value"; }
protected override void InitalizePage() { _parentForm = (FrmWizard)ParentForm; _parentForm.Text = this.StepDescription; InitLaizeComboBoxs(); if (FrmWizard.AllCollectedValues.ContainsKey("AccountSettings.AccountID")) { txtAccountID.Text = FrmWizard.AllCollectedValues["AccountSettings.AccountID"].ToString(); } if (chkAddMeasure.Checked) { txtAccountID.Enabled = true; } else { txtAccountID.Enabled = false; } stepReadyTimer.Interval = interval; stepReadyTimer.Start(); }
private void InitLaizeComboBoxs() { //Clean the combo boxs cmbBeData.DataSource = null; _BEDataValues.Clear(); //Load default values from app.config string[] googleDefaultValues = FrmWizard.GetFromWizardSettings("EdgeBI.Wizards.GoogleConversions").Split(','); foreach (string str in googleDefaultValues) { if (!_BEDataValues.ContainsKey("AccountSettings." + str)) { _BEDataValues.Add("AccountSettings." + str, str); } } _BEDataValues.Add("BEData", "BEData"); int numOfCpa = FrmWizard.GetCountLikeSettings("AccountSettings.ACQ"); for (int i = 1; i <= numOfCpa; i++) { string value = "AccountSettings.ACQ" + i.ToString(); if (!_CPAData.ContainsKey("AccountSettings." + value)) { _CPAData.Add("AccountSettings." + value, "Acquisition" + i.ToString()); } } cmbBeData.DataSource = _BEDataValues.ToList(); cmbBeData.ValueMember = "Key"; cmbBeData.DisplayMember = "Value"; cmbCPA.DataSource = _CPAData.ToList(); cmbCPA.ValueMember = "Key"; cmbCPA.DisplayMember = "Value"; }
private void txtBIScopeID_Validated(object sender, EventArgs e) { try { int scopeId; if (int.TryParse(txtBIScopeID.Text.Trim(), out scopeId)) { if (cmbWizardType.SelectedValue.ToString() == addNewBI || cmbWizardType.SelectedValue.ToString() == NewBIForActiveAccount) { using (SqlConnection sqlConnection = new SqlConnection(FrmWizard.GetFromWizardSettings("OLTP.Connection.string"))) { sqlConnection.Open(); using (SqlCommand sqlCommand = new SqlCommand(@"Select Account_Name From User_GUI_Account Where Scope_ID=@Scope_ID", sqlConnection)) { sqlCommand.Parameters.AddWithValue("@Scope_ID", int.Parse(txtBIScopeID.Text.Trim())); using (SqlDataReader reader = sqlCommand.ExecuteReader()) { if (reader.Read()) { txtBIScopName.Text = reader[0].ToString(); } } if (cmbWizardType.SelectedValue.ToString() == NewBIForActiveAccount && !string.IsNullOrEmpty(txtBIScopeID.Text)) { txtRole.Text = string.Format("Role {0}", txtBIScopeID.Text.Trim()); } } } } } } catch (Exception ex) { MessageBox.Show(ex.Message); } }