hi all,
I would like to find a solution for the following problem:
on a form I have a command button to load a subform, based on a certain table. the table is an imported table, with saved import procedure.
when clicking the button I want access to check the date of creation of the table and if it's <> current date, run the import procedure.
I've come up with this function to check the date, but it doesn't do the trick.
what am I doing wrong?
I would like to find a solution for the following problem:
on a form I have a command button to load a subform, based on a certain table. the table is an imported table, with saved import procedure.
when clicking the button I want access to check the date of creation of the table and if it's <> current date, run the import procedure.
I've come up with this function to check the date, but it doesn't do the trick.
Code:
Public Function toplevelcheck()
If CurrentDb.TableDefs("table_FOX").Properties("DateCreated").Value <> Date Then
MsgBox "update table"
DoCmd.RunSavedImportExport "Import-New Selection 1"
End If
End Function
what am I doing wrong?