Hi all. Once more I need your precious help.
I used the code below to add a new column to an existing table that works ok but I need some more things.
A. I want to add 3 columns instead of 1 and
B. I want the fields to be TEXT fields with their default values set to something let's say "No Further Action"
Can you please help me?
The code I used :
Private Sub Command1_Click()
Dim strField As String
Dim curDatabase As Object
Dim tblTest As Object
Dim fldNew As Object
Set curDatabase = CurrentDb
Set tblTest = curDatabase.TableDefs("tblTEST")
strField = "TestColumn2"
Set fldNew = tblTest.CreateField(strField, dbLong)
tblTest.Fields.Append fldNew
End Sub
Thank you in advance