Microsoft Access 2000


         

Public Function funCreateTable(strTable As String) As Boolean


Dim dbs As Database, tdf As TableDef

On Error GoTo 999 '

funCreateTable = False '

If funVerifyTable(strTable) = False Then '

Set dbs = appAccess.CurrentDb '

Set tdf = dbs.CreateTableDef(strTable) '

tdf.Fields.Append tdf.CreateField("", dbLong) ' 1

dbs.TableDefs.Append tdf '

funCreateFields strTable '<3>

funCreateTable = True '

End If

Exit Function

999:

MsgBox Err.Description, vbCritical, " " '

Err.Clear '