使用指定的属性名和集合信息初始化 DataContextValueSourceAttribute 类的新实例。
命名空间:  Microsoft.Windows.Design
程序集:  Microsoft.Windows.Design.Interaction(在 Microsoft.Windows.Design.Interaction.dll 中)
语法
声明
Public Sub New ( _
    dataContextValueSourceProperty As String, _
    isCollectionItem As Boolean _
)
public DataContextValueSourceAttribute(
    string dataContextValueSourceProperty,
    bool isCollectionItem
)
public:
DataContextValueSourceAttribute(
    String^ dataContextValueSourceProperty, 
    bool isCollectionItem
)
new : 
        dataContextValueSourceProperty:string * 
        isCollectionItem:bool -> DataContextValueSourceAttribute
public function DataContextValueSourceAttribute(
    dataContextValueSourceProperty : String, 
    isCollectionItem : boolean
)
参数
- dataContextValueSourceProperty
 类型:System.String
 表示数据上下文值的源的属性的名称。
- isCollectionItem
 类型:System.Boolean
 指示数据上下文是否为某个集合中的项。
.NET Framework 安全性
- 对直接调用方的完全信任。此成员不能由部分信任的代码使用。有关更多信息,请参见通过部分受信任的代码使用库。
请参见
参考
DataContextValueSourceAttribute 类
DataContextValueSourceAttribute 重载