共用方式為


DiscoveryExceptionDictionary.Item[String] 屬性

定義

取得或設定從 Exception 探索指定的 URL 時所發生的 DiscoveryExceptionDictionary

public:
 property Exception ^ default[System::String ^] { Exception ^ get(System::String ^ url); void set(System::String ^ url, Exception ^ value); };
public Exception this[string url] { get; set; }
member this.Item(string) : Exception with get, set
Default Public Property Item(url As String) As Exception

參數

url
String

探索文件的 URL,此文件在 XML Web Service 探索期間造成例外狀況擲回。

屬性值

Exception

探索 url 時被擲回的 Exception

例外狀況

urlnull

範例

Exception^ myException = myExceptionDictionary[ myUrlKey ];
Console::WriteLine( " Source : {0}", myException->Source );
Console::WriteLine( " Exception : {0}", myException->Message );
Exception myException = myExceptionDictionary[myUrlKey];
Console.WriteLine(" Source : " + myException.Source);
Console.WriteLine(" Exception : " + myException.Message);
Dim myException As Exception = myExceptionDictionary(myUrlKey)
Console.WriteLine(" Source : " + myException.Source)
Console.WriteLine(" Exception : " + myException.Message)

適用於