Re: Document Dropdowns Reference by macropod
macropod
Tue Feb 13 15:44:44 CST 2007
Hi,
In Word, DropDowns are formfields! Each DropDown's name is that of the bookmark it sets, which you can see if the document is
unprotected and you right-click on the field to expose its properties. You can test them in code. For example:
Sub DropDownTest()
Dim oFld As FormField
With ActiveDocument
For Each oFld In .FormFields
If oFld.Type = wdFieldFormDropDown Then
If oFld.Name = "DropDown2" then MsgBox "Found it!"
End If
Next
End With
End Sub
Cheers
--
macropod
[MVP - Microsoft Word]
"No_Spam" <no_to_spam@comcast.net> wrote in message news:1171381550.251184.36800@h3g2000cwc.googlegroups.com...
| How do I refer to a document dropdown without using its name. Like in
| Excel I use Sheet1.DropDowns(dropdown_name). How can I do that in
| Word? It's not a form fied so it does not work when I do FormFields. I
| would like to have a loop for the dropdowns in my document.
|