Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Opening a form when date is due

Status
Not open for further replies.

integritycare

Technical User
Mar 12, 2011
151
AU
Hi all,

Just a question on how to get a form to open automatically when a date becomes due.
I have a form which has staff data, such as certifciates, comptencies etc.
One of the fields on this is "DateDue".. I want this form to open when the date becomes due.ie If staff competencies are due on septmber the 1st 2012, then for that form to open so that the HR person can view the required data.

Many thanks,

Integrity
 
From an Autoexec Macro, which runs when the app first opens, you can run the DCount Function against the Table that holds your data, and if it returns a count greater than Zero, open the Form based on the same Table, and only return Records for those employees who have re-certifications that are due/overdue.

The problem with this approach, of course, is that HR may not want to bother with this when they first open the database, and nobody wants HR to start off the day being grumpy! They could minimize the Form until they're ready to it, but that requires that they actually minimize it and remember, before the end of the workday, that they haven't attended to this task!

What I would do, well, actually, what I have done, for CPR recerts, is have a Form that opens in Datasheet View and use Conditional Formatting to flag all recerts that are due/overdue by changing the Date Field to Red.

In the Conditional Formatting you'd use something like this:
[ul]
[li]Under Condition1 select Expression Is[/li]
[li]In the box to the immediate right of this enter[DueDate]<=Date()[/li]
[li]Select the Background/Foreground Colors you want[/li]
[li]Click on OK[/li]
[li][/li]
[/ul]

The Missinglinq

Richmond, Virginia

The Devil's in the Details!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top