我在Application Resource
中有以下内容 <clr:String x:Key="DecimalStringFormat">{}{0:n2}</clr:String>
<clr:String x:Key="DecimalStringFormatN2">N2</clr:String>
现在,(不工作)我有一个像这样的数据网格文本列
<DataGridTextColumn Header="AMOUNT TO USE" Binding="{Binding AmountToUse,StringFormat={StaticResource DecimalStringFormat}}">
这很好用
<DataGridTextColumn Header="AMOUNT TO USE" Binding="{Binding AmountToUse,StringFormat={StaticResource DecimalStringFormatN2}}">
任何帮助为什么第一个声明不起作用?
答案 0 :(得分:0)
let serverTrustPolicies: [String: ServerTrustPolicy] = [
"someserver.withvalidcer.com": .PinCertificates(
certificates: ServerTrustPolicy.certificatesInBundle(),
validateCertificateChain: true,
validateHost: true
)
]
let manager = Manager(
configuration: NSURLSessionConfiguration.defaultSessionConfiguration(),
serverTrustPolicyManager: ServerTrustPolicyManager(policies: serverTrustPolicies)
)
我应该删除额外的2个括号
<clr:String x:Key="DecimalStringFormat">{}{0:n2}</clr:String>