Beispiel #1
0
 private void Uloha12BtUprav_Click(object sender, RoutedEventArgs e)
 {
     try
     {
         var rodCislo   = InputUloha12RodCislo.Text;
         var idKatastru = int.Parse(InputUloha12CisloKatUzem.Text);
         var cisloListu = int.Parse(InputUloha12CisloListuVlast.Text);
         Uloha12List.ItemsSource = AfrikaKataster.Uloha12(rodCislo, cisloListu, idKatastru);
     }
     catch (Exception)
     {
         MessageBox.Show("Zle zadane vstupne parametre", "Err");
     }
 }
Beispiel #2
0
 private void Uloha12BUloz_Click(object sender, RoutedEventArgs e)
 {
     try
     {
         var idKatastru   = int.Parse(InputUloha12CisloKatUzem.Text);
         var rodCislo     = InputUloha12RodCislo.Text;
         var cisloListu   = int.Parse(InputUloha12CisloListuVlast.Text);
         var majetkovyPod = double.Parse(InputUloha12MajetkovyPodiel.Text);
         var uspech       = AfrikaKataster.Uloha12Update(rodCislo, cisloListu, idKatastru, majetkovyPod);
         if (uspech == "OK")
         {
             Uloha12List.ItemsSource = AfrikaKataster.Uloha12(rodCislo, cisloListu, idKatastru);
         }
         else
         {
             MessageBox.Show(uspech, "Err");
         }
     }
     catch (Exception)
     {
         MessageBox.Show("Zle zadane ciselne hodnoty (Majetkovy Podiel)", "Err");
     }
 }
Beispiel #3
0
 private void Uloha12BtPridaj_Click(object sender, RoutedEventArgs e)
 {
     try
     {
         var rodCislo        = InputUloha12RodCislo.Text;
         var cisloListu      = int.Parse(InputUloha12CisloListuVlast.Text);
         var cisloKatUzem    = int.Parse(InputUloha12CisloKatUzem.Text);
         var majetkovyPodiel = double.Parse(InputUloha12MajetkovyPodiel.Text);
         var uspech          = AfrikaKataster.PridajVlastnika(rodCislo, cisloListu, cisloKatUzem, majetkovyPodiel);
         if (uspech == "OK")
         {
             Uloha12List.ItemsSource = AfrikaKataster.Uloha12(rodCislo, cisloListu, cisloKatUzem);
         }
         else
         {
             MessageBox.Show(uspech, "Err");
         }
     }
     catch (Exception)
     {
         MessageBox.Show("Zle zadane parametre", "ERR");
     }
 }