Ink.CustomStrokes 属性
获取随墨迹 保存的 CustomStrokes 集合。
命名空间: Microsoft.Ink
程序集: Microsoft.Ink(在 Microsoft.Ink.dll 中)
语法
声明
Public ReadOnly Property CustomStrokes As CustomStrokes
用法
Dim instance As Ink
Dim value As CustomStrokes
value = instance.CustomStrokes
public CustomStrokes CustomStrokes { get; }
public:
property CustomStrokes^ CustomStrokes {
CustomStrokes^ get ();
}
/** @property */
public CustomStrokes get_CustomStrokes()
public function get CustomStrokes () : CustomStrokes
属性值
类型:Microsoft.Ink.CustomStrokes
随墨迹保存的 CustomStrokes 集合。
示例
在此示例中,使用指定的名称将传递的 Ink 对象的 Strokes 集合添加到该传递的 Ink 对象的 CustomStrokes 集合。如果指定的 CustomStrokes 集合已存在,则会引发异常。
Private Sub AddCustomStrokes(ByVal mName As String, ByVal mInk As Ink)
Try
' if the name already exists, an exception will be raised
mInk.CustomStrokes.Add(mName, mInk.Strokes)
Catch E As ArgumentException
' this exception is raised when the named collection already exists
End Try
End Sub
private void AddCustomStrokes(string mName, Ink mInk)
{
try
{
// if the name already exists, an exception will be raised
mInk.CustomStrokes.Add(mName, mInk.Strokes);
}
catch (ArgumentException)
{
// this exception is raised when the named collection already exists
}
}
平台
Windows Vista
.NET Framework 和 .NET Compact Framework 并不是对每个平台的所有版本都提供支持。有关支持的版本的列表,请参见.NET Framework 系统要求。
版本信息
.NET Framework
受以下版本支持:3.0