Aracılığıyla paylaş


DiscoveryExceptionDictionary.Add(String, Exception) Yöntem

Tanım

Exception anahtarına urlDiscoveryExceptionDictionaryile ekler.

public:
 void Add(System::String ^ url, Exception ^ value);
public void Add (string url, Exception value);
member this.Add : string * Exception -> unit
Public Sub Add (url As String, value As Exception)

Parametreler

url
String

XML Web hizmetleri bulma sırasında özel duruma neden olan URL.

value
Exception

Exception XML Web hizmetleri bulma sırasında oluşan.

Özel durumlar

url, null değeridir.

anahtarına url sahip bir girdi içinde DiscoveryExceptionDictionaryzaten var.

Örnekler

DiscoveryExceptionDictionary^ myNewExceptionDictionary = gcnew DiscoveryExceptionDictionary;

// Add an exception with the custom error message.
Exception^ myNewException = gcnew Exception( "The requested service is not available." );
myNewExceptionDictionary->Add( myUrlKey, myNewException );
myExceptionDictionary = myNewExceptionDictionary;
DiscoveryExceptionDictionary myNewExceptionDictionary =
                           new DiscoveryExceptionDictionary();
// Add an exception with the custom error message.
Exception myNewException =
     new Exception("The requested service is not available.");
myNewExceptionDictionary.Add(myUrlKey, myNewException);
myExceptionDictionary = myNewExceptionDictionary;
Dim myNewExceptionDictionary As New DiscoveryExceptionDictionary()
' Add an exception with the custom error message.
Dim myNewException As New Exception("The requested service is not available.")
myNewExceptionDictionary.Add(myUrlKey, myNewException)
myExceptionDictionary = myNewExceptionDictionary

Şunlara uygulanır

Ayrıca bkz.