RichTextBox.IsDocumentEnabled Özellik

Tanım

Kullanıcının ve içindeki RichTextBoxnesnelerle UIElement ContentElement etkileşimde bulunup bulunamayacağını belirten bir değer alır veya ayarlar.

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

Özellik Değeri

Boolean

true kullanıcı ile etkileşim UIElement kurabiliyorsa ve ContentElement içindeki RichTextBoxnesneler ; değilse, false.

Örnekler

Aşağıdaki örnek, ve içeren bir RichTextBox Hyperlink Buttonoluşturur.CheckBox IsDocumentEnabled özelliğinin RichTextBox özelliği, özelliğine IsChecked CheckBoxbağlıdır. Kullanıcı öğesini seçtiğinde CheckBoxve Hyperlinkile Button etkileşimde bulunabilir. Kullanıcı işaretini Button kaldırınca CheckBoxve Hyperlink devre dışı bırakılır.

<StackPanel>
    <CheckBox Name="IsDocumentEnabledChbk" Content="IsDocumentEnabled"/>
    <RichTextBox Name="richTB"
                 IsDocumentEnabled="{Binding ElementName=IsDocumentEnabledChbk,
                                             Path=IsChecked}">
        <FlowDocument>
            <Paragraph>
                Use the Checkbox above to switch between enabling and
                disabling the Button and Hyperlink in the RichTextBox.
                <Hyperlink>Here is a hyperlink</Hyperlink>
            </Paragraph>
            <BlockUIContainer>
                <Button>Click me!</Button>
            </BlockUIContainer>

        </FlowDocument>
    </RichTextBox>
</StackPanel>

Açıklamalar

IsDocumentEnabled.NET Framework sürüm 3.5'te kullanıma sunulmuştur. Daha fazla bilgi için bkz . Sürümler ve Bağımlılıklar.

Şunlara uygulanır