MainWindow.axaml 3.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081
  1. <Window
  2. xmlns="https://github.com/avaloniaui"
  3. xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
  4. xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
  5. xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
  6. mc:Ignorable="d" d:DesignWidth="1500" d:DesignHeight="450"
  7. x:Class="AvaloniaApplication2.MainWindow"
  8. Title="AvaloniaApplication2" FontSize="15">
  9. <Grid>
  10. <StackPanel Name="WritePanel" HorizontalAlignment="Center" IsVisible="True">
  11. <StackPanel Orientation ="Vertical">
  12. <StackPanel Orientation ="Horizontal">
  13. <StackPanel>
  14. <TextBlock Margin="0,20,20,0">Введите фамилию:</TextBlock>
  15. <TextBox Name ="tbLastName" Margin="0,0,20,0"></TextBox>
  16. </StackPanel>
  17. <StackPanel>
  18. <TextBlock Margin="0,20,20,0">Введите имя:</TextBlock>
  19. <TextBox Name ="tbFirstName" Margin="0,0,20,0"></TextBox>
  20. </StackPanel>
  21. <StackPanel>
  22. <TextBlock Margin="0,20,0,0">Введите отчество:</TextBlock>
  23. <TextBox Name ="tbPatronymic"></TextBox>
  24. </StackPanel>
  25. </StackPanel>
  26. <StackPanel Orientation="Horizontal">
  27. <StackPanel>
  28. <TextBlock Margin="0,20,30,0">Введите день рождения:</TextBlock>
  29. <TextBox Name ="tbBirthDay" Margin="0,0,30,0"></TextBox>
  30. </StackPanel>
  31. <StackPanel>
  32. <TextBlock Margin="0,20,0,0">Выберите месяц рождения:</TextBlock>
  33. <StackPanel>
  34. <ComboBox Name ="cbBirthMonth" SelectedIndex="0" Width="200">
  35. <ComboBoxItem>Январь</ComboBoxItem>
  36. <ComboBoxItem>Февраль</ComboBoxItem>
  37. <ComboBoxItem>Март</ComboBoxItem>
  38. <ComboBoxItem>Апрель</ComboBoxItem>
  39. <ComboBoxItem>Май</ComboBoxItem>
  40. <ComboBoxItem>Июнь</ComboBoxItem>
  41. <ComboBoxItem>Июль</ComboBoxItem>
  42. <ComboBoxItem>Август</ComboBoxItem>
  43. <ComboBoxItem>Сентябрь</ComboBoxItem>
  44. <ComboBoxItem>Октябрь</ComboBoxItem>
  45. <ComboBoxItem>Ноябрь</ComboBoxItem>
  46. <ComboBoxItem>Декабрь</ComboBoxItem>
  47. </ComboBox>
  48. </StackPanel>
  49. </StackPanel>
  50. </StackPanel>
  51. <StackPanel Orientation="Horizontal">
  52. <StackPanel>
  53. <TextBlock Margin="0,20,0,0">Введите год рождения:</TextBlock>
  54. <TextBox Name ="tbBirthYear"></TextBox>
  55. </StackPanel>
  56. <StackPanel>
  57. <TextBlock Margin="40,20,0,0">Выберите пол:</TextBlock>
  58. <StackPanel Orientation="Horizontal">
  59. <RadioButton Margin="40,0,10,0" GroupName="Genders" Name="GenderM" Content="Мужской" IsChecked="True"/>
  60. <RadioButton GroupName="Genders" Content="Женский" Name="GenderF" IsChecked="False"/>
  61. </StackPanel>
  62. </StackPanel>
  63. </StackPanel>
  64. <StackPanel Orientation="Vertical">
  65. <TextBlock Margin="0,20,0,0">Введите номер телефона:</TextBlock>
  66. <TextBox Name="tbPhone" Width="415" HorizontalAlignment="Left"></TextBox>
  67. </StackPanel>
  68. <StackPanel Orientation="Horizontal">
  69. <TextBlock Name="tErrMsg" Foreground="Red" Margin="0,15,0,0"></TextBlock>
  70. </StackPanel>
  71. <StackPanel>
  72. <Button Margin="0,20,0,0" HorizontalAlignment="Center" Click="WriteFile">Записать данные</Button>
  73. <Button Margin="0,20,0,0" HorizontalAlignment="Center" Click="ShowUsers">Показать пользователей</Button>
  74. </StackPanel>
  75. </StackPanel>
  76. </StackPanel>
  77. <StackPanel Name="UsersPanel" HorizontalAlignment="Center" IsVisible="False">
  78. <Button Click="ClickBack" Margin="0,20,0,0">Назад</Button>
  79. </StackPanel>
  80. </Grid>
  81. </Window>