在.NET中我只会写
[Editor(typeof(System.ComponentModel.Design.MultilineStringEditor), typeof(System.Drawing.Design.UITypeEditor))]
public string MultiLineText { get; set; }
获取字符串属性的多行编辑器。
然而,在 Compact Framework 中这是不可能的,因为System.ComponentModel
不包括在内。
我已经有一个DesigntimeAttributes.xmta
文件,我想我必须在这里定义它,但我找不到如何实现此目的的示例。
以下 xmta 条目在我的 VS2008 上成功了:
<Property Name="MultiLineText">
<Browsable>true</Browsable>
<Editor>
<BaseType>System.Drawing.Design.UITypeEditor, System.Drawing</BaseType>
<Type>System.ComponentModel.Design.MultilineStringEditor, System.Design</Type>
</Editor>
</Property>
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)