2
Answers

radio button and datetime picker in silverlight 3 with c#

asha m

asha m

14y
8.7k
1

Hai,
for textbox we use text to binding . And for radiobutton and datetimepicker what to use for binding. i send my code
 
<
RadioButton x:Name="rd1" Height="23" HorizontalAlignment="Left" Margin="74,165,0,0" VerticalAlignment="Top" Width="53" Content="male" Checked="rd1_checked" IsChecked="{Binding Path=gender,Mode=Twoway}" />
<RadioButton x:Name="rd2" Height="23" HorizontalAlignment="Left" Margin="150,165,0,0" VerticalAlignment="Top" Width="72" Content="female" Checked="rd2_checked" IsChecked="{Binding Path=gender,Mode=Twoway}"/>
<controls:DatePicker x:Name="txtjoin" Height="29" HorizontalAlignment="Right" Margin="0,189,210,0" VerticalAlignment="Top" Width="108" SelectedDate ="{Binding Path=dateofjoin, Mode=Twoway}"/>
for gender i used checkbox.Ischecked is used in radiobutton but  i shows wrong values in database true or false.
for datetime picker,Selecteddate is used but it doesnot display the date .
 
regards
asha
Answers (2)