Startup Question based on date

  • Thread starter Thread starter Stephen Lynch
  • Start date Start date
S

Stephen Lynch

Upgraded access to 2002 and I cannot get this to work. Basically I have
about 10 queries that run when I first open my database so, I wrote this to
check the date that I updated the table and if it is today then maximize the
startup form and not run all of the queries. I open the database multiple
times a day and do not want to wait for the queries to rerun.

Can anyone help me. I search and I think that now it support ado and this is
dao or something like that.

Here's what use to work:

If Format(DBEngine(0)(0).TableDefs("MasterHoldings").Properties(2), "Short
Date") = Format(Now(), "Short Date") Then
DoCmd.Maximize
Else

Run my queries

Thanks in advance

Steve
 
Assuming that you upgraded from ACCESS 97, then you need to set a reference
to DAO library in your ACCESS 2002 database. In Visual Basic Editor window,
click Tools | References and select Microsoft Data Access Objects (DAO) v3.x
from the list.
 
Thanks Ken,
Will Try

Ken Snell said:
Assuming that you upgraded from ACCESS 97, then you need to set a
reference to DAO library in your ACCESS 2002 database. In Visual Basic
Editor window, click Tools | References and select Microsoft Data Access
Objects (DAO) v3.x from the list.
 
DBEngine(0)(0).TableDefs("MasterHoldings").Properties(2) _

Isn't it a bit brave to index a properties collection using the ordinal
number? Is there any guarantee written anywhere that the property you want
will still be in position 2 even after changing versions?


Tim F
 
Back
Top