在UWP的XAML中使用原string, double 等原始类型

 

问题:
I'm trying to access the system namespace for StaticResource variables in XAML on UWP. Here's (mostly) what I'm using:



    
        260
    

    foo

Even though the  shows in IntelliSense as valid, I'm getting the following runtime error:

An exception of type 'Windows.UI.Xaml.Markup.XamlParseException' occurred in mscorlib.ni.dll but was not handled in user code

WinRT information: Cannot deserialize XBF metadata type list as 'Double' was not found in namespace 'System'. [Line: 0 Position: 0]
I'm open to other ways of declaring a double if this method will not work.
解决方案:
Turns out it's in the default x: namespace.



    
        260
    

    foo

 

你可能感兴趣的:(windows,10,UWP)