Silverlight windows phone中的XAML字符串格式

Silverlight windows phone中的XAML字符串格式,silverlight,xaml,windows-phone-7,windows-phone-8,Silverlight,Xaml,Windows Phone 7,Windows Phone 8,如何以给定格式格式化DateTime(7/24/13,11:24 AM),我找到了一个选项,可以以类似的方式格式化字符串[Text=“{Binding CreatedDate,StringFormat={0:g}}”],但我不能在日期和时间之间添加(,)逗号。如何在windows phone中执行此操作。目前使用字符串格式,我得到的日期如下(7/24/13 11:24 am)。 我会给你 2013年8月22日上午11:52 <TextBlock Text="{Binding Date,

如何以给定格式格式化DateTime(7/24/13,11:24 AM),我找到了一个选项,可以以类似的方式格式化字符串[Text=“{Binding CreatedDate,StringFormat={0:g}}”],但我不能在日期和时间之间添加(,)逗号。如何在windows phone中执行此操作。目前使用字符串格式,我得到的日期如下(7/24/13 11:24 am)。


我会给你

2013年8月22日上午11:52

<TextBlock Text="{Binding Date, StringFormat='{}{0:MM/dd/yyyy, h:mm tt}'}" />