私はユーザーがデータを入力する入力フィールドを持っていて、テキストが変わるたびにキャプチャして、ユーザーが入力したデータと一致するものがあるかどうかを照会して結果を表示します。Entryフィールドのすべての変更をキャプチャする方法は?
<StackLayout Grid.Row="0" Grid.Column="0" Padding="16,13,16,9">
<StackLayout Orientation="Horizontal" Padding="10,0">
<StackLayout.GestureRecognizers>
<TapGestureRecognizer Tapped="OnTapVINRecognizer"/>
</StackLayout.GestureRecognizers>
<local:CustomLabel x:Name="VINLabel" Text="VIN" TextColor="#3680a4" Style="{StaticResource AccordTitleStyle}"/>
<Image x:Name="VINImage" Source="arrow_down.png"/>
</StackLayout>
<StackLayout x:Name="VINAccordion" IsVisible="True" Padding="0,5,0,16" Spacing="10">
<StackLayout Spacing="0" Orientation="Horizontal">
<local:CustomEntry x:Name="VINText" Placeholder="17 CHARACTERS" HorizontalOptions="FillAndExpand"/>
</StackLayout>
<local:CustomLabel Style="{StaticResource AccordLabelStyle}">
<local:CustomLabel.Text>
If the motor has a VIN, enter the VIN. A VIN is the 17 character identifier recorded on most vehicles built after 1998
</local:CustomLabel.Text>
</local:CustomLabel>
<local:CustomButton Clicked="OnClickSearchBtn" ClassId="vin"/>
</StackLayout>
</StackLayout>
この行は、ユーザーの入力は、テキスト:
<StackLayout Spacing="0" Orientation="Horizontal">
<local:CustomEntry x:Name="VINText" Placeholder="17 CHARACTERS" HorizontalOptions="FillAndExpand"/>
</StackLayout>
どのように私は、テキストにそれが変わるたびにキャプチャしますか?その後に結果が表示される場合、どうすれば表示されますか? UはTextChangedイベントを準備していますが、使用方法がわかりません。このシナリオに適用可能ですか?助けを前にありがとう。
はあなたがそれに答えるためにしようとしている人々を支援するよう、質問に関連していないXAMLを削除してくださいすることができます。 –