how to delete all data in a table, not its structure

lamha

Registered User.
Local time
Today, 10:14
Joined
Jun 21, 2000
Messages
76
I have a graph that is based on a table. After I close that graph, I want all the data in that table is deleted. So the next time I select a new item and view the graph, this table will contain the new data of the new selected item. Does any know how to do this? Any help would be appreciated.
 
I think I answered this question at another site.

Public Function fDeleteTblRecords(strTblName As String)
Dim strSQL As String
strSQL = "Delete * from " & strTblName
CurrentDb().Execute strSQL
End Function

Useage example:
fDeleteTblRecords("YourTableName")

HTH
RDH


[This message has been edited by R. Hicks (edited 08-16-2000).]
 
It worked. Thank you very much, Hicks.
 

Users who are viewing this thread

Back
Top Bottom