ToolBarTray.IsLocked 屬性

定義

取得或設定值,指出 ToolBar 是否可在 ToolBarTray 內移動。

public:
 property bool IsLocked { bool get(); void set(bool value); };
public bool IsLocked { get; set; }
member this.IsLocked : bool with get, set
Public Property IsLocked As Boolean

屬性值

Boolean

如果無法在工具列匣內移動工具列,則為 true;否則為 false。 預設為 false

範例

下列範例示範如何建立 ToolBarTray 不允許 在其中移動的 ToolBar

<ToolBarTray Background="White" IsLocked="True">

備註

這個相依性屬性也有附加的屬性使用方式。

XAML Attribute Usage

<object IsLocked="bool"/>  
- or -  
<object ToolBarTray.IsLocked="bool"/>  

相依性屬性資訊

識別碼欄位 IsLockedProperty
設定為 的中繼資料屬性 true AffectsMeasure, Inherits

適用於

另請參閱