IVsWritableSettingsStore.SetBinary 方法

设置二进制属性的值与指定的字节数组的。如果属性以前的数据类型不是 SettingsType_Binary,此方法将其复盖。如果属性不存在,则创建一个

命名空间:  Microsoft.VisualStudio.Shell.Interop
程序集:   Microsoft.VisualStudio.Shell.Interop.10.0(在 Microsoft.VisualStudio.Shell.Interop.10.0.dll 中)
  Microsoft.VisualStudio.Shell.11.0(在 Microsoft.VisualStudio.Shell.11.0.dll 中)

语法

声明
Function SetBinary ( _
    collectionPath As String, _
    propertyName As String, _
    byteLength As UInteger, _
    pBytes As Byte() _
) As Integer
int SetBinary(
    string collectionPath,
    string propertyName,
    uint byteLength,
    byte[] pBytes
)

参数

  • pBytes
    类型:array<System.Byte[]
    [in] 写入的字节。

返回值

类型:System.Int32
,如果设置属性,返回 S_OK 。如果集合不存在,则方法返回 E_INVALIDARG。

备注

如果 byteLength 为 0,则 pBytes 可以为空,但是,它应否则指向字节指定的范围。

.NET Framework 安全性

请参见

参考

IVsWritableSettingsStore 接口

Microsoft.VisualStudio.Shell.Interop 命名空间