Range.ContentControls property (Word)
Returns a ContentControls collection that represents the content controls contained within a range. Read-only.
Syntax
expression. ContentControls
expression An expression that returns a Range object.
Example
The following example inserts a drop-down list content control into the active document at the specified position.
Dim objCC As ContentControl
Dim objRange as Range
Set objRange = ActiveDocument.Range(200, 200)
Set objCC = objRange.ContentControls.Add(wdContentControlDropdownList)
'List entries
objCC.DropdownListEntries.Add "Cat"
objCC.DropdownListEntries.Add "Dog"
objCC.DropdownListEntries.Add "Horse"
objCC.DropdownListEntries.Add "Monkey"
objCC.DropdownListEntries.Add "Snake"
objCC.DropdownListEntries.Add "Other"
See also
Support and feedback
Have questions or feedback about Office VBA or this documentation? Please see Office VBA support and feedback for guidance about the ways you can receive support and provide feedback.
Geri Bildirim
https://aka.ms/ContentUserFeedback.
Çok yakında: 2024 boyunca, içerik için geri bildirim mekanizması olarak GitHub Sorunları’nı kullanımdan kaldıracak ve yeni bir geri bildirim sistemiyle değiştireceğiz. Daha fazla bilgi için bkz.Gönderin ve geri bildirimi görüntüleyin