MessageQueueEnumerator.Close 方法

定義

釋放與列舉值相關的資源。Frees the resources associated with the enumerator.

public:
 void Close();
public void Close ();
member this.Close : unit -> unit
Public Sub Close ()

備註

作業系統會在資料指標存留期間, LocatorHandle將開啟的控制碼保留在佇列列舉值中。The operating system retains an open handle, LocatorHandle, to the queue enumerator during the lifetime of the cursor. 當您完成使用列舉值時, 請Close呼叫以釋放與控制碼相關聯的資源。When you finish working with the enumerator, call Close to release the resources associated with the handle.

適用於

另請參閱