
Signature
Greetings from Bavaria, Germany
Helmut Weber, MVP WordVBA
Win XP, Office 2003
"red.sys" & Chr$(64) & "t-online.de"
Thank you so much!
One question; does the '3' in "If Left(oFrm.Name, 3)" refer to the
length of the character string?
Also, should this work even to reset dropdown menu selections?
Again, thanks!
TMan
Doug Robbins - Word MVP - 05 May 2006 19:22 GMT
Yes, that is what it does mean. I suggest however that you take a bit of
time and check the Visual Basic help file for the meaning of things. To get
context sensitive help, press F1 when the selection is immediately after the
item about which you want to know something. In this case after the t of
Left.

Signature
Hope this helps.
Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.
Doug Robbins - Word MVP
> Thank you so much!
>
[quoted text clipped - 6 lines]
>
> TMan
Helmut Weber - 05 May 2006 20:24 GMT
Hi TomorrowsMan,
>Also, should this work even to reset dropdown menu selections?
Maybe you mean to reset the dropdown list,
so that the first item in the list is displayed,
instead of any other item the user may have selected.
Sub ClearNums2()
Dim oFrm As FormField
For Each oFrm In ActiveDocument.FormFields
If Left(oFrm.Name, 3) = "Num" Then ' case sensitive !
If oFrm.Type = wdFieldFormDropDown Then
oFrm.DropDown.Value = 1 ' < !
Else
oFrm.Result = ""
End If
End If
Next
End Sub
HTH

Signature
Greetings from Bavaria, Germany
Helmut Weber, MVP WordVBA
Win XP, Office 2003
"red.sys" & Chr$(64) & "t-online.de"