質問編集履歴
1
該当ソースコード追加と前提の追加
test
CHANGED
File without changes
|
test
CHANGED
@@ -6,11 +6,19 @@
|
|
6
6
|
|
7
7
|
|
8
8
|
|
9
|
+
xamlで宣言したラベルに対して、
|
10
|
+
|
9
|
-
xaml.cs側で
|
11
|
+
xaml.cs側でテキストなどに、値を入れる際に
|
10
12
|
|
11
13
|
「testPage.LblMessage'と'testPage.LblMessage'間があいまいです。」
|
12
14
|
|
13
15
|
と同じクラス間であいまいとエラーが出てしまいます。
|
16
|
+
|
17
|
+
|
18
|
+
|
19
|
+
xaml側で宣言した全てのコントロールのプロパティに値を入れる際に、
|
20
|
+
|
21
|
+
エラーが発生しています。
|
14
22
|
|
15
23
|
|
16
24
|
|
@@ -34,8 +42,130 @@
|
|
34
42
|
|
35
43
|
|
36
44
|
|
37
|
-
```
|
45
|
+
```c#
|
38
46
|
|
47
|
+
//xaml
|
48
|
+
|
49
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
50
|
+
|
51
|
+
<ContentPage xmlns="http://xamarin.com/schemas/2014/forms"
|
52
|
+
|
53
|
+
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
|
54
|
+
|
55
|
+
x:Class="test.Views.GroupCreatingPage">
|
56
|
+
|
57
|
+
<StackLayout Orientation="Vertical"
|
58
|
+
|
59
|
+
Spacing="20"
|
60
|
+
|
61
|
+
VerticalOptions="CenterAndExpand"
|
62
|
+
|
63
|
+
HorizontalOptions="CenterAndExpand">
|
64
|
+
|
65
|
+
<Image Source="blue_folder.png" WidthRequest="200" HeightRequest="200"/>
|
66
|
+
|
67
|
+
<Entry x:Name="edtGroupName"
|
68
|
+
|
69
|
+
FontSize="Large"
|
70
|
+
|
71
|
+
HorizontalTextAlignment="Start"
|
72
|
+
|
73
|
+
HorizontalOptions="FillAndExpand"
|
74
|
+
|
75
|
+
VerticalOptions="Center" />
|
76
|
+
|
77
|
+
<StackLayout Orientation="Horizontal"
|
78
|
+
|
79
|
+
Spacing="20">
|
80
|
+
|
81
|
+
<Button x:Name="BtnChange"
|
82
|
+
|
83
|
+
VerticalOptions="Center"
|
84
|
+
|
85
|
+
BackgroundColor="#e0e2e5"
|
86
|
+
|
87
|
+
BorderColor="#e0e2e5"
|
88
|
+
|
89
|
+
BorderWidth="1"
|
90
|
+
|
91
|
+
TextColor="Black"
|
92
|
+
|
39
|
-
|
93
|
+
WidthRequest="150"
|
94
|
+
|
95
|
+
Clicked="OkButtonClicked" />
|
96
|
+
|
97
|
+
|
98
|
+
|
99
|
+
<Button x:Name="BtnCancel"
|
100
|
+
|
101
|
+
VerticalOptions="Center"
|
102
|
+
|
103
|
+
BackgroundColor="#e0e2e5"
|
104
|
+
|
105
|
+
BorderColor="#e0e2e5"
|
106
|
+
|
107
|
+
BorderWidth="1"
|
108
|
+
|
109
|
+
TextColor="Black"
|
110
|
+
|
111
|
+
WidthRequest="150"
|
112
|
+
|
113
|
+
Clicked="CancelButtonClicked" />
|
114
|
+
|
115
|
+
</StackLayout>
|
116
|
+
|
117
|
+
</StackLayout>
|
118
|
+
|
119
|
+
</ContentPage>
|
120
|
+
|
121
|
+
|
122
|
+
|
123
|
+
|
124
|
+
|
125
|
+
//xmal.cs
|
126
|
+
|
127
|
+
public partial class GroupCreatingPage : ContentPage
|
128
|
+
|
129
|
+
{
|
130
|
+
|
131
|
+
CarLocker CarLockers;
|
132
|
+
|
133
|
+
|
134
|
+
|
135
|
+
public GroupCreatingPage(CarLocker car)
|
136
|
+
|
137
|
+
{
|
138
|
+
|
139
|
+
InitializeComponent();
|
140
|
+
|
141
|
+
CarLockers = car;
|
142
|
+
|
143
|
+
|
144
|
+
|
145
|
+
BtnChange.Text = AppResources.Button_Change;//エラー発生箇所
|
146
|
+
|
147
|
+
BtnCancel.Text = AppResources.Button_Cancel;//エラー発生箇所
|
148
|
+
|
149
|
+
if (CarLockers != null)
|
150
|
+
|
151
|
+
{
|
152
|
+
|
153
|
+
edtGroupName.Text = CarLockers.CarNumber;//エラー発生箇所
|
154
|
+
|
155
|
+
}
|
156
|
+
|
157
|
+
else
|
158
|
+
|
159
|
+
{
|
160
|
+
|
161
|
+
edtGroupName.Text = "";//エラー発生箇所
|
162
|
+
|
163
|
+
}
|
164
|
+
|
165
|
+
edtGroupName.TextChanged += EdtGroupName_TextChanged;//エラー発生箇所
|
166
|
+
|
167
|
+
}
|
168
|
+
|
169
|
+
}
|
40
170
|
|
41
171
|
```
|