如何最轻松地确定某个属性是否为依赖项属性?

编程入门 行业动态 更新时间:2024-10-21 13:12:32
本文介绍了如何最轻松地确定某个属性是否为依赖项属性?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

我最近在将数据绑定到DataGridTextColumn的Visibility属性时遇到问题。之所以引起混乱,是因为该属性在WPF中是一个依赖属性,而在Silverlight中却不是。

I recently had an issue with databinding to the Visibility property of a DataGridTextColumn. The confusion arose because this property is a dependecy property in WPF but not in Silverlight.

我认为MSDN文档并不十分清楚。以下是WPF的唯一相关文本。

I don't think that the MSDN documentation makes this very clear. The following is the only related text for WPF.

有关可影响该值的信息,请参阅DependencyProperty。

"For information about what can influence the value, see DependencyProperty."

msdn.microsoft/zh-cn/library/system.windows.controls.datagridcolumn.visibility(v=VS.100).aspx

推荐答案

相关性属性在其定义的类上具有一个对应的静态字段。请查看 DataGridTextColumn 类。

Dependency properties have a corresponding static field on the class they are defined in. Have a look at the fields section of the DataGridTextColumn class.

更多推荐

如何最轻松地确定某个属性是否为依赖项属性?

本文发布于:2023-11-08 07:40:43,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1568759.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:属性   轻松

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!