I have a Label in a XAML code like this:
<Label
x:Name="lblPhoneNo"
Text="{Binding ConsumerPersonData.TelephoneNumber}"
Style="{StaticResource dataLabel}"
Grid.Row="3" >
Grid.Column="1" />
I want to pass the value of that Label in a CommandProperty when a button is click. My button code below:
<Button
Text="Call"
TextColor="White"
WidthRequest="100"
Command="{Binding CallCommand}"
CommandParameter="{Binding ElementName=lblPhoneNo, Path=Text}"
BackgroundColor="{x:Static common:ColorResources.ButtonBackgroundColor}" />
What am I missing here?