public override void CarregarEntidadeDoForm() { entidade.ClearNotifications(); entidade.Endereco.ClearNotifications(); cidade.SetValidations(); pessoa.SetValidations(); marca.SetValidations(); Placa placa = new Placa(txtPlaca.Text, TipoPlaca.Comum); Endereco endereco = new Endereco(txtEnderecoLogradouro.Text.ToUpper().Trim(), txtEnderecoNumero.Text.ToUpper().Trim(), cidade, txtEnderecoBairro.Text.ToUpper().Trim(), txtEnderecoComplemento.Text.ToUpper().Trim(), txtEnderecoCEP.Text.ToUpper().Trim(), txtEnderecoCaixaPostal.Text.ToUpper().Trim()); VeiculoCategoria categoria = (VeiculoCategoria)txtCategoria.SelectedItem; VeiculoEspecie especie = (VeiculoEspecie)txtEspecie.SelectedItem; VecimentoLicenciamento licenciamento = (VecimentoLicenciamento)txtLicenciamento.SelectedItem; entidade.SetValues(placa, txtRenavam.Text.ToUpper().Trim(), txtChassi.Text.ToUpper().Trim(), txtMotor.Text.ToUpper().Trim(), txtAnoFab.Text.ToUpper().Trim(), txtAnoMod.Text.ToUpper().Trim(), txtDescricaoModelo.Text.ToUpper().Trim(), txtEspelho.Text.ToUpper().Trim(), txtCombustivel.Text.ToUpper().Trim(), txtCor.Text.ToUpper().Trim(), categoria, especie, licenciamento, endereco, pessoa, marca, metroCheckBox1.Checked, txtNomePropAnterior.Text.Trim().ToUpper(), txtCpfCnpjPropAnterior.Text.Trim().ToUpper(), txtDataCompra.Text.Trim().ToUpper().ToUpper(), txtValorCompra.Text.Trim().ToUpper(), txtNumeroNotaCompra.Text.Trim().ToUpper()); entidade.NomeComprador = txtCompradorNome.Text.Trim().ToUpper(); entidade.CpfCnpjComprador = txtCompradorCpfCnpj.Text.Trim().ToUpper(); entidade.DataVenda = txtCompradorData.Text.Trim().ToUpper(); entidade.ValorVenda = txtCompradorValor.Text.Trim().ToUpper(); }