I am trying to write code to add a field called "Additional" to an existing
table called "Faculty". When I run it as an on click event, it stops at the
line, .append fldTemp with the error message Run-time error '3191': Cannot
define field more than once.
Can someone please point out the error to me.
dixie
Private Sub AddField_Click()
Dim dbs As DAO.Database
Dim tdfFaculty As DAO.TableDef
Dim fldTemp As Field
Set dbs = CurrentDb()
Set tdfFaculty = dbs.TableDefs("Faculty")
Set fldTemp = tdfFaculty.CreateField("Additional", dbText, 255)
With tdfFaculty.Fields
.Append fldTemp
End With
End Sub