共用方式為


ConfigurationSection.SerializeSection 方法

定義

建立 XML 字串,在該字串的單一區段中,包含了要寫入檔案之 ConfigurationSection 物件的取消合併檢視。

protected:
 virtual System::String ^ SerializeSection(System::Configuration::ConfigurationElement ^ parentElement, System::String ^ name, System::Configuration::ConfigurationSaveMode saveMode);
protected public:
 virtual System::String ^ SerializeSection(System::Configuration::ConfigurationElement ^ parentElement, System::String ^ name, System::Configuration::ConfigurationSaveMode saveMode);
protected virtual string SerializeSection (System.Configuration.ConfigurationElement parentElement, string name, System.Configuration.ConfigurationSaveMode saveMode);
protected internal virtual string SerializeSection (System.Configuration.ConfigurationElement parentElement, string name, System.Configuration.ConfigurationSaveMode saveMode);
abstract member SerializeSection : System.Configuration.ConfigurationElement * string * System.Configuration.ConfigurationSaveMode -> string
override this.SerializeSection : System.Configuration.ConfigurationElement * string * System.Configuration.ConfigurationSaveMode -> string
Protected Overridable Function SerializeSection (parentElement As ConfigurationElement, name As String, saveMode As ConfigurationSaveMode) As String
Protected Friend Overridable Function SerializeSection (parentElement As ConfigurationElement, name As String, saveMode As ConfigurationSaveMode) As String

參數

parentElement
ConfigurationElement

ConfigurationElement 執行個體,要用來做為執行取消合併時的父代。

name
String

要建立的區段名稱。

saveMode
ConfigurationSaveMode

要在寫入至字串時所使用的 ConfigurationSaveMode 執行個體。

傳回

XML 字串,包含了 ConfigurationSection 物件的取消合併檢視。

備註

串行化是指將物件中包含的實時數據轉換成 XML 格式,並將其記憶體轉換成組態檔。

適用於