/// <summary> /// On 'Close' button click /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void btnClose_Click(object sender, EventArgs e) { try { if (Messages.CloseConfirmation()) { this.Close(); } else { this.Close(); } } catch (Exception ex) { formMDI.infoError.ErrorString = "ROREG14:" + ex.Message; } }
/// <summary> /// On 'Close' button click /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void btnClose_Click(object sender, EventArgs e) { try { if (Messages.CloseConfirmation()) { this.Close(); } else { this.Close(); } } catch (Exception ex) { MessageBox.Show("SRR9" + ex.Message, "OpenMiracle", MessageBoxButtons.OK, MessageBoxIcon.Information); } }
/// <summary> /// Frorm keydown /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void frmBatch_KeyDown(object sender, KeyEventArgs e) { try { if (e.KeyCode == Keys.Escape) { //if (PublicVariables.isMessageClose) //{ // Messages.CloseMessage(this); //} //else //{ // this.Close(); //} if (Messages.CloseConfirmation()) { this.Close(); } } if (e.KeyCode == Keys.S && Control.ModifierKeys == Keys.Control) //Save { if (cmbProduct.Focused) { cmbProduct.DropDownStyle = ComboBoxStyle.DropDown; } else { cmbProduct.DropDownStyle = ComboBoxStyle.DropDownList; } btnSave_Click(sender, e); } if (e.KeyCode == Keys.D && Control.ModifierKeys == Keys.Control) //Delete { if (btnDelete.Enabled) { btnDelete_Click(sender, e); } } } catch (Exception ex) { MessageBox.Show("B25:" + ex.Message, "OpenMiracle", MessageBoxButtons.OK, MessageBoxIcon.Information); } }
/// <summary> /// Frorm keydown /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void frmBatch_KeyDown(object sender, KeyEventArgs e) { try { if (e.KeyCode == Keys.Escape) { //if (PublicVariables.isMessageClose) //{ // Messages.CloseMessage(this); //} //else //{ // this.Close(); //} if (Messages.CloseConfirmation()) { this.Close(); } } if (e.KeyCode == Keys.S && Control.ModifierKeys == Keys.Control) //Save { if (cmbProduct.Focused) { cmbProduct.DropDownStyle = ComboBoxStyle.DropDown; } else { cmbProduct.DropDownStyle = ComboBoxStyle.DropDownList; } btnSave_Click(sender, e); } if (e.KeyCode == Keys.D && Control.ModifierKeys == Keys.Control) //Delete { if (btnDelete.Enabled) { btnDelete_Click(sender, e); } } } catch (Exception ex) { formMDI.infoError.ErrorString = "B26:" + ex.Message; } }
/// <summary> /// On close button click /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void btnClose_Click(object sender, EventArgs e) { try { //Jamshi //if (PublicVariables.isMessageClose) //{ // Messages.CloseMessage(this); //} //else //{ // this.Close(); //} if (Messages.CloseConfirmation()) { this.Close(); } } catch (Exception ex) { MessageBox.Show("B12:" + ex.Message, "OpenMiracle", MessageBoxButtons.OK, MessageBoxIcon.Information); } }
/// <summary> /// On close button click /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void btnClose_Click(object sender, EventArgs e) { try { //Jamshi //if (PublicVariables.isMessageClose) //{ // Messages.CloseMessage(this); //} //else //{ // this.Close(); //} if (Messages.CloseConfirmation()) { this.Close(); } } catch (Exception ex) { formMDI.infoError.ErrorString = "B13:" + ex.Message; } }
/// <summary> /// For shortcut key /// Esc for formclose /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void frmAccountGroupwiseReport_KeyDown(object sender, KeyEventArgs e) { try { if (e.KeyCode == Keys.Escape) { if (Messages.CloseConfirmation()) { if (frmCashFlowObj != null) { int inCount = arrlstGroupId.Count; if (inCount != 1) { { decAccountGroupId = Convert.ToDecimal(arrlstGroupId[inCount - 2].ToString()); arrlstGroupId.RemoveAt(inCount - 1); if (decAccountGroupId == 2) { CashflowLoansGridFill(); } else if (decAccountGroupId == 6) { CashOutflowCurrentAssetGridFill(); } else { CashflowCommonGridFill(); } } } else { this.Close(); } } else if (objfrmFundFlow != null) { int inCount = arrlstGroupId.Count; if (inCount != 1) { decAccountGroupId = Convert.ToDecimal(arrlstGroupId[inCount - 2].ToString()); if (decAccountGroupId == 6) { arrlstGroupId.RemoveAt(inCount - 1); GridFillForFundFlow(decClosingStockGroupWise); } else { arrlstGroupId.RemoveAt(inCount - 1); GridFill(); } } else { this.Close(); } } else { int inCount = arrlstGroupId.Count; if (inCount != 1) { decAccountGroupId = Convert.ToDecimal(arrlstGroupId[inCount - 2].ToString()); arrlstGroupId.RemoveAt(inCount - 1); GridFill(); } else { this.Close(); } } } } } catch (Exception ex) { formMDI.infoError.ErrorString = "AGWREP22:" + ex.Message; } }