IVsDataViewHierarchy.InsertItem 方法 (Int32, String, Int32, array<Object[])
插入指定的節點中指定的父節點下方。
命名空間: Microsoft.VisualStudio.Data.Services.SupportEntities
組件: Microsoft.VisualStudio.Data.Services (在 Microsoft.VisualStudio.Data.Services.dll 中)
語法
'宣告
Function InsertItem ( _
parentItemId As Integer, _
typeName As String, _
newItemId As Integer, _
identifier As Object() _
) As Boolean
bool InsertItem(
int parentItemId,
string typeName,
int newItemId,
Object[] identifier
)
bool InsertItem(
int parentItemId,
String^ typeName,
int newItemId,
array<Object^>^ identifier
)
abstract InsertItem :
parentItemId:int *
typeName:string *
newItemId:int *
identifier:Object[] -> bool
function InsertItem(
parentItemId : int,
typeName : String,
newItemId : int,
identifier : Object[]
) : boolean
參數
parentItemId
類型:Int32新節點的父代的完整名稱。
typeName
類型:String新的節點型別的名稱。
newItemId
類型:Int32新節點的數值識別項可以插入。
identifier
類型:array<Object[]包含表示新結構的識別組件的陣列。
傳回值
類型:Boolean
true ,如果插入節點;否則, false。
例外狀況
例外狀況 | 條件 |
---|---|
ArgumentNullException | typeName 參數為 nullnull 參考 (即 Visual Basic 中的 Nothing)。 |
.NET Framework 安全性
- 完全信任立即呼叫者。這個成員無法供部分信任的程式碼使用。如需詳細資訊,請參閱從部分受信任程式碼使用程式庫。