Example #1
0
        private void SetFieldsUpdateFormAdress()
        {
            var gettingAdress = _crudStudent.GetAdress(_currentRowAdressIndex);

            TypeAdressComboBox.Text     = DictionaryForRefreshDataTables.GetAdressTypeEnumToString(gettingAdress.adressType);
            StreetTextBox.Text          = gettingAdress.street;
            CityTextBox.Text            = gettingAdress.city;
            PostIndexMaskedTextBox.Text = gettingAdress.postindex;
        }
Example #2
0
        private void RefreshDataTableAdress(Student student, DataTable dataTableAdress)
        {
            dataTableAdress.Rows.Clear();

            foreach (var element in student.addressList)
            {
                dataTableAdress.Rows.Add(DictionaryForRefreshDataTables.GetAdressTypeEnumToString(element.adressType),
                                         element.city, element.postindex, element.street);
            }
        }
Example #3
0
        private void AddRowsDataTableAdress(List <Adress> adressList, DataTable dataTable)
        {
            dataTable.Rows.Clear();

            foreach (var element in adressList)
            {
                dataTable.Rows.Add(DictionaryForRefreshDataTables.GetAdressTypeEnumToString(element.adressType),
                                   element.city, element.postindex, element.street);
            }
        }