The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.
XmlBinaryWriterSession::TryAdd Method (XmlDictionaryString^, Int32%)
.NET Framework (current version)
Tries to add an XmlDictionaryString to the internal collection.
Assembly: System.Runtime.Serialization (in System.Runtime.Serialization.dll)
Parameters
- value
-
Type:
System.Xml::XmlDictionaryString^
The XmlDictionaryString to add.
- key
-
Type:
System::Int32%
The key of the XmlDictionaryString that was successfully added.
| Exception | Condition |
|---|---|
| ArgumentNullException | value is null. |
| InvalidOperationException | An entry with key = key already exists. |
When you use this class you must override this method to send the collection of keys along with the message. Without overriding, a new key is added to the collection, which is saved, but not sent with the message.
Universal Windows Platform
Available since 8
.NET Framework
Available since 3.0
Portable Class Library
Supported in: portable .NET platforms
Silverlight
Available since 4.0
Windows Phone Silverlight
Available since 8.0
Windows Phone
Available since 8.1
Available since 8
.NET Framework
Available since 3.0
Portable Class Library
Supported in: portable .NET platforms
Silverlight
Available since 4.0
Windows Phone Silverlight
Available since 8.0
Windows Phone
Available since 8.1
Show: