Aracılığıyla paylaş


XMLNodes.Parent Özellik

Alır bir Microsoft.Office.Interop.Word.Document temsil eden belgeyi içeren XMLNodes koleksiyonu.

Ad alanı:  Microsoft.Office.Tools.Word
Derleme:  Microsoft.Office.Tools.Word (Microsoft.Office.Tools.Word.dll içinde)

Sözdizimi

'Bildirim
ReadOnly Property Parent As Object
    Get
Object Parent { get; }

Özellik Değeri

Tür: System.Object
A Microsoft.Office.Interop.Word.Document temsil eden belgeyi içeren XMLNodes koleksiyonu.

Örnekler

Aşağıdaki kod örneği Parent ana belgenin adını görüntülemek için özellik bir XMLNodes koleksiyonu. Bu örnek, geçerli belge içerdiğini varsayar bir XMLNodes Denetim adlı SampleInsertNodes.

Private Sub DisplayParentName()
    Dim document1 As Word.Document = _
        CType(Me.SampleInsertNodes.Parent, Word.Document)

    MsgBox("The parent of SampleInsertNodes" & _
        " is named " & document1.Name)

End Sub
private void DisplayParentName()
{
    Word.Document document1 =
        (Word.Document)this.SampleInsertNodes.Parent;

    MessageBox.Show("The parent of SampleInsertNodes" +
        " is named " + document1.Name);
}

.NET Framework Güvenliği

Ayrıca bkz.

Başvuru

XMLNodes Arabirim

Microsoft.Office.Tools.Word Ad Alanı