'删除表(包括链接表)的三个函数caoguangyao2011-6-13
'1.----------------------------------
Public Function delTable(tbl As String)
'功能: 删除表
'参数: tbl--->表名称
'示例:delTable ("部门")
DoCmd.DeleteObject acTable, tbl
End Function
'2---------------------------------
Public Function delTable2(tbl As String)
'功能: 删除表
'参数: tbl--->表名称
'示例:delTable2 ("部门")
Dim dbs As Database
Set dbs = CurrentDb
dbs.TableDefs.Delete tbl
dbs.Close
End Function
'3.------------------------------
Public Function delTable3(tbl As String)
'功能: 删除表
'参数: tbl--->表名称
'示例:delTable3 ("部门")
Dim dbs As Database
Set dbs = CurrentDb
dbs.Execute "Drop table " & tbl
dbs.Close
End Function