WorkflowMarkupSerializationManager.IDesignerSerializationManager.CreateInstance 方法
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
建立指定型態的實例,並將其加入一組命名實例中。
virtual System::Object ^ System.ComponentModel.Design.Serialization.IDesignerSerializationManager.CreateInstance(Type ^ type, System::Collections::ICollection ^ arguments, System::String ^ name, bool addToContainer) = System::ComponentModel::Design::Serialization::IDesignerSerializationManager::CreateInstance;
object IDesignerSerializationManager.CreateInstance(Type type, System.Collections.ICollection arguments, string name, bool addToContainer);
abstract member System.ComponentModel.Design.Serialization.IDesignerSerializationManager.CreateInstance : Type * System.Collections.ICollection * string * bool -> obj
override this.System.ComponentModel.Design.Serialization.IDesignerSerializationManager.CreateInstance : Type * System.Collections.ICollection * string * bool -> obj
Function CreateInstance (type As Type, arguments As ICollection, name As String, addToContainer As Boolean) As Object Implements IDesignerSerializationManager.CreateInstance
參數
- arguments
- ICollection
一個 ICollection 包含 的 type參數。
- name
- String
物件的名稱。 此名稱可用於日後使用 IDesignerSerializationManager.GetInstance(String)。 如果傳入空參考(Nothing in Visual Basic),該物件仍會被建立,但無法以名稱存取。
- addToContainer
- Boolean
true將物件加入設計容器;否則,。 false
傳回
新創造的物品。
實作
備註
若 addToContainer 設為 true,物件必須實作 IComponent 此操作才會產生效果。