/// <summary> /// Handles Load event for mold data Insert/Update operations /// Loading mold data for update mold data and binding controls with selected mold record /// </summary> /// <param name="sender"></param> /// <param name="e"></param> protected void AddMoldForm_Load(object sender, EventArgs e) { if (!this.DesignMode) { this.ProductionDate_dtp.Clear(); FormDatatableFromVo(); ComboBind(MoldType_cmb, moldTypeDatatable, "code", "id"); MoldCode_txt.Select(); if (string.Equals(mode, CommonConstants.MODE_UPDATE)) { LoadUserData(updateData); MoldCode_txt.Enabled = false; MoldName_txt.Select(); } } }
/// <summary> /// Handles Load event for mold data Insert/Update operations /// Loading mold data for update mold data and binding controls with selected mold record /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void AddMoldNewForm_Load(object sender, EventArgs e) { this.ProductionDate_dtp.Clear(); FormDatatableFromVo(); ComboBind(MoldType_cmb, moldTypeDatatable, "code", "id"); MoldCode_txt.Select(); int ProcessMoldId = 0; if (string.Equals(mode, CommonConstants.MODE_UPDATE)) { LoadUserData(updateData); ProcessMoldId = updateData.MoldId; MoldCode_txt.Enabled = false; MoldName_txt.Select(); } BindGrid(ProcessMoldId); }