public virtual CloudAccountDA.FeatureContentMasterDataTable GetData() { this.Adapter.SelectCommand = this.CommandCollection[0]; CloudAccountDA.FeatureContentMasterDataTable dataTable = new CloudAccountDA.FeatureContentMasterDataTable(); this.Adapter.Fill(dataTable); return(dataTable); }
protected void btnUpdate_Click(object sender, EventArgs e) { try { if (this.Page.IsValid) { if (this.ddlFeatureCategory.SelectedIndex > 0 && this.edContent.Content.Trim().Length > 0) { this.objFeatureContentMasterDT = this.objFeatureContentMasterBll.GetDataByFeatureContentID(int.Parse(this.hfFeatureContent.Value.Trim())); if (this.objFeatureContentMasterBll.UpdateFeatureContent(int.Parse(this.hfFeatureContent.Value.Trim()), int.Parse(this.ddlFeatureCategory.SelectedItem.Value), this.edContent.Content, this.chkStatus.Checked)) { this.DisplayAlert("Update Successfully.."); this.Response.Redirect("~/BillTransact/FeatureContentMaster.aspx?cmd=view&ID=" + this.Request.QueryString["ID"]); } else { this.DisplayAlert("Fail to Update Details."); } } else { this.DisplayAlert("Please Fill All Details...!"); } } else { this.DisplayAlert("Fail to Update Details."); } } catch (Exception ex) { this.DisplayAlert(ex.Message); } }
public virtual int Fill(CloudAccountDA.FeatureContentMasterDataTable dataTable) { this.Adapter.SelectCommand = this.CommandCollection[0]; if (this.ClearBeforeFill) { dataTable.Clear(); } return(this.Adapter.Fill(dataTable)); }
private void ViewRecord(string i) { this.objFeatureContentMasterDT = this.objFeatureContentMasterBll.GetDataByFeatureContentID(int.Parse(i)); if (this.objFeatureContentMasterDT.Rows.Count <= 0) { return; } this.hfFeatureContent.Value = this.objFeatureContentMasterDT.Rows[0]["FeatureContentID"].ToString(); this.lblContent.Text = this.objFeatureContentMasterDT.Rows[0]["FeatureContent"].ToString(); this.lblStatus.Text = this.objFeatureContentMasterDT.Rows[0]["Status"].ToString() == "True" ? "True" : "False"; this.lblFeatureCategory.Text = this.objFeatureContentMasterDT.Rows[0]["FeatureCategoryID"].ToString(); this.objFeatureCategoryMasterDT = this.objFeatureCategoryMasterBll.GetDataByFeatureCategoryID(int.Parse(this.lblFeatureCategory.Text)); this.lblFeatureCategory.Text = this.objFeatureCategoryMasterDT.Rows[0]["FeatureCategoryName"].ToString(); }
public virtual CloudAccountDA.FeatureContentMasterDataTable GetDataByFeatureCategoryID(int?FeatureCategoryID) { this.Adapter.SelectCommand = this.CommandCollection[1]; if (FeatureCategoryID.HasValue) { this.Adapter.SelectCommand.Parameters[1].Value = FeatureCategoryID.Value; } else { this.Adapter.SelectCommand.Parameters[1].Value = DBNull.Value; } CloudAccountDA.FeatureContentMasterDataTable dataTable = new CloudAccountDA.FeatureContentMasterDataTable(); this.Adapter.Fill(dataTable); return(dataTable); }
private void SetRecord(string iD) { this.objFeatureContentMasterDT = this.objFeatureContentMasterBll.GetDataByFeatureContentID(int.Parse(iD)); if (this.objFeatureContentMasterDT.Rows.Count <= 0) { return; } this.hfFeatureContent.Value = this.objFeatureContentMasterDT.Rows[0]["FeatureContentID"].ToString(); this.objFeatureCategoryMasterDT = this.objFeatureCategoryMasterBll.GetDataByFeatureCategoryID(int.Parse(this.objFeatureContentMasterDT.Rows[0]["FeatureCategoryID"].ToString())); if (this.objFeatureCategoryMasterDT.Rows.Count > 0) { this.ddlFeatureCategory.Items.Add(this.objFeatureCategoryMasterDT.Rows[0]["FeatureCategoryID"].ToString()); this.ddlFeatureCategory.SelectedValue = this.objFeatureCategoryMasterDT.Rows[0]["FeatureCategoryID"].ToString(); } this.edContent.Content = this.objFeatureContentMasterDT.Rows[0]["FeatureContent"].ToString(); this.chkStatus.Checked = this.objFeatureContentMasterDT.Rows[0]["Status"].ToString() == "True"; }
public virtual int Update(CloudAccountDA.FeatureContentMasterDataTable dataTable) { return(this.Adapter.Update(dataTable)); }