' Get all the fields from a PDF file ' expC1 File Private Function GetFields(ByVal tcFile As String) As Boolean Dim loAcroFields As iTextSharp.text.pdf.AcroFields = Nothing Dim loDictionaryEntry As DictionaryEntry = Nothing Dim loPdfReader As iTextSharp.text.pdf.PdfReader = Nothing ' Get the file loPdfReader = New iTextSharp.text.pdf.PdfReader(tcFile) ' Get the fields loAcroFields = loPdfReader.AcroFields ' For each field For Each loDictionaryEntry In loAcroFields.Fields Next Return True End FunctionAs you can see, this example is very sample. But, the designer doesn't like the loAcroFields.Fields in the For/Next loop. It says: