Hello,

I use this macro to import word form data to excel. I find this macro online. Macro works fine with form textfields, but in my form are some dropdown lists and macro in excel put some squares instead of values. Can someone help me, what should I change in code that will import dropdown list values to?

Here is macro:

Sub getWordFormData()
Dim wdApp As New Word.Application
Dim myDoc As Word.Document
Dim FmFld As Word.FormField
Dim myFolder As String, strFile As String
Dim myWkSht As Worksheet, i As Long, j As Long
myFolder = "C:\Users\oddelek.a\Desktop\Testna"
Application.ScreenUpdating = False
If myFolder = "" Then Exit Sub
Set myWkSht = ActiveSheet
Range("A1") = "Vrstaporočila"
Range("A1").Font.Bold = True
Range("B1") = "Priimek"
Range("B1").Font.Bold = True
Range("C1") = "Ime"
Range("C1").Font.Bold = True
Range("D1") = "Rojstnipodatki"
Range("D1").Font.Bold = True
Range("E1") = "Datum"
Range("E1").Font.Bold = True
Range("F1") = "Ura"
Range("F1").Font.Bold = True
Range("G1") = "Izmena"
Range("G1").Font.Bold = True
Range("H1") = "Služba"
Range("H1").Font.Bold = True
Range("I1") = "Status"
Range("I1").Font.Bold = True
Range("J1") = "Mesto"
Range("J1").Font.Bold = True
Range("K1") = "Vrsta"
Range("K1").Font.Bold = True
i = myWkSht.Cells(myWkSht.Rows.Count, 1).End(xlUp).Row
strFile = Dir(myFolder & "\*.doc", vbNormal)

While strFile <> ""
i = i + 1
Set myDoc = wdApp.Documents.Open(Filename:=myFolder & "" & strFile, AddToRecentFiles:=False, Visible:=False)
With myDoc
j = 0
For Each FmFld In .FormFields
j = j + 1
myWkSht.Cells(i, j) = FmFld.Range
Next
myWkSht.Columns.AutoFit
End With
myDoc.Close SaveChanges:=False
strFile = Dir()
Wend
wdApp.Quit
Set myDoc = Nothing: Set wdApp = Nothing: Set myWkSht = Nothing
Application.ScreenUpdating = True

End Sub