DirectorySearcher.Tombstone 屬性

定義

取得或設定值,指出搜尋是否還應傳回符合搜尋篩選條件的已刪除物件。

public:
 property bool Tombstone { bool get(); void set(bool value); };
public bool Tombstone { get; set; }
[System.DirectoryServices.DSDescription("DSTombstone")]
[System.Runtime.InteropServices.ComVisible(false)]
public bool Tombstone { get; set; }
member this.Tombstone : bool with get, set
[<System.DirectoryServices.DSDescription("DSTombstone")>]
[<System.Runtime.InteropServices.ComVisible(false)>]
member this.Tombstone : bool with get, set
Public Property Tombstone As Boolean

屬性值

如果搜尋中應包含已刪除物件則為 true,否則為 false。 預設值是 false

屬性

範例

下列 C# 範例示範如何將 屬性設定 Tombstonetrue

using System.DirectoryServices;  
...  
// Create a DirectorySearcher object.  
DirectorySearcher src = new DirectorySearcher("(isDeleted=true)");  
//Set the Tombstone property to true.  
src.Tombstone = true;  
//Use the FindAll method to get search results.  
SearchResultCollection res = src.FindAll();  

適用於