internal void EditRequestMethod() { try { ExcelLib.PopulateInCollection(Base.ExcelPath, "TenantMyRequest"); //validate if User is on My requests page Driver.driver.PageSource.Contains("My Requests"); //Get Job Description from Excel sheet and search TxtSearchBar.SendKeys(ExcelLib.ReadData(2, "Job Description")); BtnSearch.Click(); Driver.wait(2); LnqSortBy.Click(); //validate if Job Description is as selected string JobDescription = Driver.driver.FindElement(By.XPath("html/body/div/section/div[1]/div[5]/div[1]/div/div/div/div[2]/div[3]/div/div[2]/span")).Text; JobDescription.Contains(ExcelLib.ReadData(2, "Job Description")); //Edit the Job Description and Submit the form LnqEdit.Click(); TxtDescription.SendKeys(ExcelLib.ReadData(2, "New Description")); BtnSave.Submit(); //Validate the success message //string message = Driver.driver.FindElement(By.XPath("html/body/div/section/div[3]/div[2]/form")).Text; string message = Driver.driver.SwitchTo().Alert().Text; Assert.AreEqual(message, "Item edited successfully"); } catch (Exception Ex) { throw Ex; } }
public void ControlEnableDisable(bool trb, bool fld) { BtnNew.Enabled = trb; BtnEdit.Enabled = trb; BtnDelete.Enabled = trb; BtnExit.Enabled = trb; BtnFirstData.Enabled = trb; BtnNextData.Enabled = trb; BtnLastData.Enabled = trb; BtnPreviousData.Enabled = trb; if (BtnNew.Enabled == true) { BtnNew.Focus(); } TxtDescription.Enabled = fld; BtnSearcMemberTypeDesc.Enabled = fld; Utility.EnableDesibleColor(TxtDescription, fld); TxtDiscountPercent.Enabled = fld; Utility.EnableDesibleColor(TxtDiscountPercent, fld); CbActive.Enabled = fld; BtnSave.Enabled = fld; BtnCancel.Enabled = fld; if (BtnNew.Enabled == true) { BtnNew.Focus(); } else if (TxtDescription.Enabled == true) { TxtDescription.Focus(); } }
private void SetData(DataSet ds) { DataTable dt1 = ds.Tables[0]; ChkMandatoryOption.Checked = dt1.Rows[0]["MandotaryOpt"].ToString() == "Y" ? true : false; ChkAllowDuplicate.Checked = dt1.Rows[0]["AllowDuplicate"].ToString() == "Y" ? true : false; TxtDescription.Text = dt1.Rows[0]["FieldName"].ToString(); CmbFieldType.SelectedItem = dt1.Rows[0]["FieldType"].ToString(); TxtFieldWidth.Text = dt1.Rows[0]["FieldWidth"].ToString(); TxtPosition.Text = dt1.Rows[0]["UdfPosition"].ToString(); TxtFieldDecimal.Text = dt1.Rows[0]["FieldDecimal"].ToString(); TxtDateFormat.SelectedItem = dt1.Rows[0]["DateFormat"].ToString(); if (dt1.Rows[0]["FieldType"].ToString() == "List") { DataTable dt2 = ds.Tables[1]; GridList.Visible = true; int i = 1; foreach (DataRow dr in dt2.Rows) { GridList.Rows[GridList.Rows.Count - 1].Cells["SNo"].Value = i; GridList.Rows[GridList.Rows.Count - 1].Cells["Description"].Value = dr["ListName"].ToString(); GridList.Rows.Add(); i++; } } TxtDescription.SelectAll(); }
public void ControlEnableDisable(bool trb, bool fld) { BtnNew.Enabled = trb; BtnEdit.Enabled = trb; BtnDelete.Enabled = trb; BtnExit.Enabled = trb; BtnFirstData.Enabled = trb; BtnNextData.Enabled = trb; BtnLastData.Enabled = trb; BtnPreviousData.Enabled = trb; TxtDescription.Enabled = fld; BtnSearcTableDesc.Enabled = fld; Utility.EnableDesibleColor(TxtDescription, fld); TxtShortName.Enabled = fld; Utility.EnableDesibleColor(TxtShortName, fld); CmbFloor.Enabled = fld; Utility.EnableDesibleComboBoxColor(CmbFloor, fld); CmbType.Enabled = fld; Utility.EnableDesibleComboBoxColor(CmbType, fld); CbActive.Enabled = fld; BtnSave.Enabled = fld; BtnCancel.Enabled = fld; if (BtnNew.Enabled == true) { BtnNew.Focus(); } else if (TxtDescription.Enabled == true) { TxtDescription.Focus(); } }
internal void EditProfile() { //Populate the Excel Sheet Global.ExcelLib.PopulateInCollection(Base.ExcelPath, "Profile"); GlobalDefinitions.Wait(); EditProfileicon.Click(); EditFirstName.Clear(); EditFirstName.SendKeys(ExcelLib.ReadData(2, "FirstName")); EditLasttName.Clear(); EditLasttName.SendKeys(ExcelLib.ReadData(2, "LastName")); ProfileSaveBtn.Click(); GlobalDefinitions.driver.Navigate().Refresh(); GlobalDefinitions.Wait(); Availability.Click(); AvailabilityTime.SendKeys(ExcelLib.ReadData(2, "Availability")); Hours.Click(); AvailabilityHour.SendKeys(ExcelLib.ReadData(2, "SelectHours")); GlobalDefinitions.Wait(); EarnTarget.Click(); AvailabilityTarget.SendKeys(ExcelLib.ReadData(2, "EarnTraget")); GlobalDefinitions.Wait(); DescriptionBtn.Click(); TxtDescription.Clear(); GlobalDefinitions.Wait(); TxtDescription.SendKeys(ExcelLib.ReadData(2, "EditDesc")); DesSaveButton.Click(); }
protected void Page_Load(object sender, EventArgs e) { try { if (!IsPostBack) { BindGrid(); if (Request.QueryString["ID"] != null) { ds = cn.RunSql("sp_SearchAddLess 'S','" + Request.QueryString["ID"].ToString() + "','3'", "Search"); if (ds.Tables[0].Rows.Count > 0) { TxtDescription.Text = ds.Tables[0].Rows[0]["cDescription"] != DBNull.Value ? ds.Tables[0].Rows[0]["cDescription"].ToString() : ""; DdlAddLess.SelectedValue = ds.Tables[0].Rows[0]["cAddless"] != DBNull.Value ? ds.Tables[0].Rows[0]["cAddless"].ToString() : "+"; TxtPer.Text = ds.Tables[0].Rows[0]["nPer"] != DBNull.Value ? ds.Tables[0].Rows[0]["nPer"].ToString() : "0"; TxtRs.Text = ds.Tables[0].Rows[0]["nRs"] != DBNull.Value ? ds.Tables[0].Rows[0]["nRs"].ToString() : "0"; DDLCountBelow.SelectedValue = ds.Tables[0].Rows[0]["nCountOnTotal"] != DBNull.Value ? ds.Tables[0].Rows[0]["nCountOnTotal"].ToString() : "0"; DDLType.SelectedValue = ds.Tables[0].Rows[0]["cAccountType"] != DBNull.Value ? ds.Tables[0].Rows[0]["cAccountType"].ToString() : ""; TxtAccount.Text = ds.Tables[0].Rows[0]["cname"] != DBNull.Value ? ds.Tables[0].Rows[0]["cname"].ToString() : ""; HIDAccount.Value = ds.Tables[0].Rows[0]["cAccountID"] != DBNull.Value ? ds.Tables[0].Rows[0]["cAccountID"].ToString() : ""; //TxtDescription.Text = ds.Tables[0].Rows[0]["cDescription"] != DBNull.Value ? ds.Tables[0].Rows[0]["cDescription"].ToString() : ""; } } TxtDescription.Focus(); } } catch (Exception ex) { } }
protected void BindGrid() { ds = cn.RunSql("sp_SearchAddLess 'Grid','','3'", "Search"); GVaddless.DataSource = ds; GVaddless.DataBind(); TxtDescription.Focus(); }
private void BtnSearchDescription_Click(object sender, EventArgs e) { Common.PickList frmPickList = new Common.PickList("ProductScheme", _SearchKey); if (Common.PickList.dt.Rows.Count > 0) { frmPickList.ShowDialog(); if (frmPickList.SelectedList.Count > 0 && _Tag != "NEW") { _SchemeId = Convert.ToInt32(frmPickList.SelectedList[0]["SchemeId"].ToString().Trim()); DataSet ds = _objProductScheme.GetDataProductScheme(this._SchemeId); SetData(ds); } else { TxtDescription.Text = ""; } frmPickList.Dispose(); } else { MessageBox.Show("No List Available in Product Scheme !", "Mr. Solution", MessageBoxButtons.OK, MessageBoxIcon.Information); TxtDescription.Focus(); return; } TxtDescription.Focus(); }
public void ControlEnableDisable(bool trb, bool fld) { BtnNew.Enabled = trb; BtnEdit.Enabled = trb; BtnDelete.Enabled = trb; BtnExit.Enabled = trb; TxtDescription.Enabled = fld; BtnSearchDescription.Enabled = fld; Utility.EnableDesibleColor(TxtDescription, fld); BtnSearchDescription.Enabled = fld; TxtDateFrom.Enabled = fld; Utility.EnableDesibleDateColor(TxtDateFrom, fld); TxtDateTo.Enabled = fld; Utility.EnableDesibleDateColor(TxtDateTo, fld); TxtPercentRate.Enabled = fld; Utility.EnableDesibleColor(TxtPercentRate, fld); ControlRadioButton(false); BtnSave.Enabled = fld; BtnCancel.Enabled = fld; if (BtnNew.Enabled == true) { BtnNew.Focus(); } else if (TxtDescription.Enabled == true) { TxtDescription.Focus(); } }
public void EnableDisable(bool trb, bool fld) { BtnNew.Enabled = trb; BtnEdit.Enabled = trb; BtnDelete.Enabled = trb; BtnExit.Enabled = trb; BtnFirstData.Enabled = trb; BtnNextData.Enabled = trb; BtnLastData.Enabled = trb; BtnPreviousData.Enabled = trb; if (BtnNew.Enabled == true) { BtnNew.Focus(); } BtnSearchCounterDesc.Enabled = fld; TxtDescription.Enabled = fld; Utility.EnableDesibleColor(TxtDescription, fld); TxtShortName.Enabled = fld; Utility.EnableDesibleColor(TxtShortName, fld); TxtGodown.Enabled = fld; Utility.EnableDesibleColor(TxtGodown, fld); CmbPrinterName.Enabled = fld; Utility.EnableDesibleComboBoxColor(CmbPrinterName, fld); CbActive.Enabled = fld; BtnSave.Enabled = fld; BtnCancel.Enabled = fld; if (BtnNew.Enabled == true) { BtnNew.Focus(); } else if (TxtDescription.Enabled == true) { TxtDescription.Focus(); } }
//private void AddList() //{ // Dictionary<string, string> _CmbType = new Dictionary<string, string> // { // { "BS", "Balance Sheet" }, // { "PL", "Profit & Loss" }, // { "TD", "Trading" } // }; // CmbType.Items.Clear(); // CmbType.DataSource = new BindingSource(_CmbType, null); // CmbType.DisplayMember = "Value"; // CmbType.ValueMember = "Key"; // CmbType.SelectedIndex = 0; // Dictionary<string, string> _CmbPrimaryGroup = new Dictionary<string, string> // { // { "Assets", "Assets" }, // { "Liability", "Liability" }, // { "Income", "Income" }, // { "Expenditure", "Expenditure" } // }; // CmbPrimaryGroup.Items.Clear(); // CmbPrimaryGroup.DataSource = new BindingSource(_CmbPrimaryGroup, null); // CmbPrimaryGroup.DisplayMember = "Value"; // CmbPrimaryGroup.ValueMember = "Key"; // CmbPrimaryGroup.SelectedIndex = 0; //} public void ControlEnableDisable(bool trb, bool fld) { BtnNew.Enabled = trb; BtnEdit.Enabled = trb; BtnDelete.Enabled = trb; BtnExit.Enabled = trb; BtnFirstData.Enabled = trb; BtnNextData.Enabled = trb; BtnLastData.Enabled = trb; BtnPreviousData.Enabled = trb; BtnSearcAccountDesc.Enabled = fld; TxtDescription.Enabled = fld; Utility.EnableDesibleColor(TxtDescription, fld); TxtShortName.Enabled = fld; Utility.EnableDesibleColor(TxtShortName, fld); CmbType.Enabled = fld; CmbPrimaryGroup.Enabled = fld; TxtSchedule.Enabled = fld; Utility.EnableDesibleColor(TxtSchedule, fld); CbActive.Enabled = fld; BtnSave.Enabled = fld; BtnCancel.Enabled = fld; if (BtnNew.Enabled == true) { BtnNew.Focus(); } else if (TxtDescription.Enabled == true) { TxtDescription.Focus(); } }
private void BtnDescription_Click(object sender, EventArgs e) { ClsGlobal.SalesmanType = "Member"; Common.PickList frmPickList = new Common.PickList("SalesMan", _SearchKey); if (Common.PickList.dt.Rows.Count > 0) { frmPickList.ShowDialog(); if (frmPickList.SelectedList.Count > 0 && _Tag != "NEW") { DataTable dt = _objSalesman.GetDataMember(Convert.ToInt32(frmPickList.SelectedList[0]["SalesmanId"].ToString().Trim())); SetData(dt); } else { TxtDescription.Tag = "0"; TxtDescription.Text = ""; } frmPickList.Dispose(); } else { MessageBox.Show("No List Available in Membership !", "Mr. Solution", MessageBoxButtons.OK, MessageBoxIcon.Information); TxtDescription.Focus(); return; } TxtDescription.Focus(); }
private void BtnClear_Click(object sender, RoutedEventArgs e) { TxtDescription.Clear(); TxtTreatment.Clear(); CmbPlayer.SelectedIndex = 0; CmbPredisposition.SelectedIndex = 0; }
public void LoadEditContent() { ComboBoxUnitQty.ItemsSource = CatalogTable.SelectFromCatalogTable(); ComboBoxUnitQty.DisplayMemberPath = "CatalogValue"; ComboBoxUnitQty.SelectedValuePath = "CatalogId"; var product = ProductTable.SelectSingleProduct(Pid); TxtTitle.Text = product.ProductName; TxtPrice.Text = product.ProductUnitPrice.ToString(); TxtQty.Text = product.ProductCount.ToString(); TxtDescription.Text = string.Empty; TxtDescription.AppendText(product.ProductDescription); var ppl = product.ProductPopularSupport; if (ppl) { YesToPpl.IsChecked = true; } else { NoToPpl.IsChecked = true; } if (product.Catalog != null) { ComboBoxUnitQty.SelectedValue = product.Catalog.CatalogId; } }
private void PreferenceTreeView_SelectedItemChanged(object sender, RoutedPropertyChangedEventArgs <object> e) { if (e.NewValue is TreeViewItem) { TreeViewItem item = (TreeViewItem)e.NewValue; Binding binding = new Binding(); binding.ElementName = "PreferenceTreeView"; binding.Path = new PropertyPath("SelectedItem.Header"); PreferenceTitle.SetBinding(TextBlock.TextProperty, binding); string description = GetDescription(item); if (string.IsNullOrEmpty(description)) { TxtDescription.Visibility = Visibility.Collapsed; } else { var descriptionString = GisEditor.LanguageManager.GetStringResource(description); if (!string.IsNullOrEmpty(descriptionString)) { TxtDescription.SetResourceReference(TextBlock.TextProperty, description); } else { TxtDescription.Text = description; } TxtDescription.Visibility = Visibility.Visible; } PreferenceContent.Content = item.Tag; } }
void ReleaseDesignerOutlets() { if (TxtGroupName != null) { TxtGroupName.Dispose(); TxtGroupName = null; } if (TxtDescription != null) { TxtDescription.Dispose(); TxtDescription = null; } if (BtnAdd != null) { BtnAdd.Dispose(); BtnAdd = null; } if (BtnClose != null) { BtnClose.Dispose(); BtnClose = null; } }
private void BtnSearchDepartmentDesc_Click(object sender, EventArgs e) { Common.PickList frmPickList = new Common.PickList("Department", _SearchKey); if (Common.PickList.dt.Rows.Count > 0) { frmPickList.ShowDialog(); if (frmPickList.SelectedList.Count > 0 && _Tag != "NEW") { DataTable dt = _objDepartment.GetDataDepartment(Convert.ToInt32(frmPickList.SelectedList[0]["DepartmentId"].ToString().Trim())); SetData(dt); TxtDescription.SelectAll(); } else { TxtDescription.Text = ""; TxtDescription.Tag = "0"; } frmPickList.Dispose(); } else { MessageBox.Show("No List Available in Department !", "Mr. Solution", MessageBoxButtons.OK, MessageBoxIcon.Information); TxtDescription.Focus(); return; } TxtDescription.Focus(); }
/// <summary> /// this will add a course to the List view to be saved when the employee is created /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void BtnAddCourse_Click(object sender, EventArgs e) { foreach (ListViewItem item in LVxCourses.Items) { if (item.SubItems[0].Text == TxtCourseID.Text) { if (MessageBox.Show("Course already exists would you like to update the record.", "Update", MessageBoxButtons.YesNo) == DialogResult.Yes) { LVxCourses.Items.Remove(item); } else { return; } } } ListViewItem lvi = new ListViewItem(TxtCourseID.Text); if (TxtDescription.Text != "") { lvi.SubItems.Add(TxtDescription.Text); } else { LblStatus.Text = "Please enter a value for the Description"; TxtDescription.Focus(); } if (TxtGrade.Text != "") { lvi.SubItems.Add(TxtGrade.Text); } else { LblStatus.Text = "Please enter a value for the Grade"; TxtGrade.Focus(); } if (TxtDateApproved.Text != "") { lvi.SubItems.Add(TxtDateApproved.Text); } else { LblStatus.Text = "Please enter a value for the Date Approved"; TxtDateApproved.Focus(); } if (TxtCredits.Text != "") { lvi.SubItems.Add(TxtCredits.Text); } else { LblStatus.Text = "Please enter a value for the Credits."; TxtCredits.Focus(); } //checkbox value lvi.SubItems.Add(CkbApproved.Checked.ToString()); LVxCourses.Items.Add(lvi); ClearEducation(); }
public void ControlEnableDisable(bool trb, bool fld) { BtnNew.Enabled = trb; BtnEdit.Enabled = trb; BtnDelete.Enabled = trb; BtnExit.Enabled = trb; BtnFirstData.Enabled = trb; BtnNextData.Enabled = trb; BtnLastData.Enabled = trb; BtnPreviousData.Enabled = trb; TxtDescription.Enabled = fld; Utility.EnableDesibleColor(TxtDescription, fld); TxtShortName.Enabled = fld; Utility.EnableDesibleColor(TxtShortName, fld); TxtAddress.Enabled = fld; Utility.EnableDesibleColor(TxtAddress, fld); TxtCity.Enabled = fld; Utility.EnableDesibleColor(TxtCity, fld); TxtContactPerson.Enabled = fld; Utility.EnableDesibleColor(TxtContactPerson, fld); TxtPhoneNo.Enabled = fld; Utility.EnableDesibleColor(TxtPhoneNo, fld); TxtCountry.Enabled = fld; Utility.EnableDesibleColor(TxtCountry, fld); TxtEmail.Enabled = fld; Utility.EnableDesibleColor(TxtEmail, fld); TxtFax.Enabled = fld; Utility.EnableDesibleColor(TxtFax, fld); TxtContactPersonMobileNo.Enabled = fld; Utility.EnableDesibleColor(TxtContactPersonMobileNo, fld); TxtContactPersonPhoneNo.Enabled = fld; Utility.EnableDesibleColor(TxtContactPersonPhoneNo, fld); TxtContactPerson.Enabled = fld; Utility.EnableDesibleColor(TxtContactPerson, fld); TxtContactPersonAdd.Enabled = fld; Utility.EnableDesibleColor(TxtContactPersonAdd, fld); TxtState.Enabled = fld; Utility.EnableDesibleColor(TxtState, fld); TxtCity.Enabled = fld; Utility.EnableDesibleColor(TxtCity, fld); BtnSave.Enabled = fld; BtnCancel.Enabled = fld; if (BtnNew.Enabled == true) { BtnNew.Focus(); } else if (TxtDescription.Enabled == true) { TxtDescription.Focus(); } }
public void FillOfferForm(string offerName, string offerDescription, string price) { TxtName.SendKeys(offerName); TxtDescription.SendKeys(offerDescription); TxtPrice.SendKeys(price); ButtonSubmit.Click(); }
private void SetData(DataTable dt) { TxtDescription.Tag = dt.Rows[0]["ProductUnitId"].ToString(); TxtDescription.Text = dt.Rows[0]["ProductUnitDesc"].ToString(); TxtShortName.Text = dt.Rows[0]["ProductUnitShortName"].ToString(); CbActive.Checked = Convert.ToBoolean(dt.Rows[0]["Status"].ToString()); TxtDescription.SelectAll(); }
public void ApplyViewModel(IViewModel viewModel) { DataContext = viewModel; if (!((SaveTaskDialogViewModel)DataContext).IsInSelectionMode) { TxtDescription.Focus(); } }
private void SetData(DataTable dt) { TxtDescription.Tag = dt.Rows[0]["MemberTypeId"].ToString(); TxtDescription.Text = dt.Rows[0]["MemberTypeDesc"].ToString(); TxtDiscountPercent.Text = ClsGlobal.DecimalFormate(Convert.ToDecimal(dt.Rows[0]["DiscountPercent"].ToString()), 1, ClsGlobal._QtyDecimalFormat).ToString(); CbActive.Checked = Convert.ToBoolean(dt.Rows[0]["Status"].ToString()); TxtDescription.SelectAll(); }
private void SetData(DataTable dt) { TxtDescription.Tag = dt.Rows[0]["DepartmentId"].ToString(); TxtDescription.Text = dt.Rows[0]["DepartmentDesc"].ToString(); TxtShortName.Text = dt.Rows[0]["DepartmentShortName"].ToString(); CmbType.Text = dt.Rows[0]["DepartmentLevel"].ToString(); CbActive.Checked = Convert.ToBoolean(dt.Rows[0]["Status"].ToString()); TxtDescription.SelectAll(); }
/// <summary> /// this will clear all the educational fields /// </summary> private void ClearEducation() { CkbApproved.Checked = true; TxtCourseID.Clear(); TxtGrade.Clear(); TxtDescription.Clear(); TxtDateApproved.Clear(); TxtCredits.Clear(); }
private void BtnClear_Click(object sender, RoutedEventArgs e) { TxtDescription.Clear(); TxtTreatment.Clear(); CmbPlayer.SelectedIndex = 0; CmbInjury.SelectedIndex = 0; DpInjury.SelectedDate = null; DpRecovery.SelectedDate = null; }
void ReleaseDesignerOutlets() { if (TxtConfirmPassword != null) { TxtConfirmPassword.Dispose(); TxtConfirmPassword = null; } if (TxtDescription != null) { TxtDescription.Dispose(); TxtDescription = null; } if (TxtEmail != null) { TxtEmail.Dispose(); TxtEmail = null; } if (TxtFirstName != null) { TxtFirstName.Dispose(); TxtFirstName = null; } if (TxtLastName != null) { TxtLastName.Dispose(); TxtLastName = null; } if (TxtPassword != null) { TxtPassword.Dispose(); TxtPassword = null; } if (TxtUserName != null) { TxtUserName.Dispose(); TxtUserName = null; } if (BtnAdd != null) { BtnAdd.Dispose(); BtnAdd = null; } if (BtnClose != null) { BtnClose.Dispose(); BtnClose = null; } }
private void Window_Loaded(object sender, RoutedEventArgs e) { TxtDescription.Focus(); TxtAmount.SelectionStart = TxtAmount.Text.Length; LoadEmployees(); LoadExpense(); }
private void SetData(DataTable dt) { TxtDescription.Tag = dt.Rows[0]["ProductGrpId"].ToString(); TxtDescription.Text = dt.Rows[0]["ProductGrpDesc"].ToString(); TxtShortName.Text = dt.Rows[0]["ProductGrpShortName"].ToString(); CmbPrinter.SelectedValue = dt.Rows[0]["PrinterName"].ToString(); TxtMargin.Text = Convert.ToDecimal(ClsGlobal.Val(dt.Rows[0]["Margin"].ToString())).ToString("0.00"); CbActive.Checked = Convert.ToBoolean(dt.Rows[0]["Status"].ToString()); TxtDescription.SelectAll(); }
private void SetData(DataTable dt) { TxtDescription.Tag = dt.Rows[0]["TableId"].ToString(); TxtDescription.Text = dt.Rows[0]["TableDesc"].ToString(); TxtShortName.Text = dt.Rows[0]["TableShortName"].ToString(); CmbFloor.SelectedValue = dt.Rows[0]["FloorId"].ToString(); CmbType.Text = dt.Rows[0]["TableStatus"].ToString(); CbActive.Checked = Convert.ToBoolean(dt.Rows[0]["Status"].ToString()); TxtDescription.SelectAll(); }