ConfigurationElementCollection.SerializeElement(XmlWriter, Boolean) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Writes the configuration data to an XML element in the configuration file when overridden in a derived class.
protected public:
override bool SerializeElement(System::Xml::XmlWriter ^ writer, bool serializeCollectionKey);
protected:
override bool SerializeElement(System::Xml::XmlWriter ^ writer, bool serializeCollectionKey);
protected internal override bool SerializeElement (System.Xml.XmlWriter writer, bool serializeCollectionKey);
protected override bool SerializeElement (System.Xml.XmlWriter writer, bool serializeCollectionKey);
override this.SerializeElement : System.Xml.XmlWriter * bool -> bool
Protected Friend Overrides Function SerializeElement (writer As XmlWriter, serializeCollectionKey As Boolean) As Boolean
Protected Overrides Function SerializeElement (writer As XmlWriter, serializeCollectionKey As Boolean) As Boolean
Parameters
- writer
- XmlWriter
Output stream that writes XML to the configuration file.
- serializeCollectionKey
- Boolean
true
to serialize the collection key; otherwise, false
.
Returns
true
if the ConfigurationElementCollection was written to the configuration file successfully.
Exceptions
One of the elements in the collection was added or replaced and starts with the reserved prefix "config" or "lock".
Remarks
The SerializeElement method writes the contents of the configuration elements contained in the collection and any nested elements they contain to the configuration file. Override SerializeElement to provide a custom write procedure out of the collection contents and nested elements.
Applies to
.NET
피드백
https://aka.ms/ContentUserFeedback
출시 예정: 2024년 내내 콘텐츠에 대한 피드백 메커니즘으로 GitHub 문제를 단계적으로 폐지하고 이를 새로운 피드백 시스템으로 바꿀 예정입니다. 자세한 내용은 다음을 참조하세요.다음에 대한 사용자 의견 제출 및 보기