Input field data from last created recorded

Vargasman

Registered User.
Local time
Today, 01:25
Joined
Sep 26, 2006
Messages
19
How would I automatically fill in a field on a form with the data from the last created record from another table?

example:
TicketInfoForm IDnumber=001 > TicketOutageForm InfoIDnumber=001
TicketInfoForm IDnumber=002 > TicketOutageForm InfoIDnumber=002
........................................ > TicketOutageForm InfoIDnumber=002
........................................ > TicketOutageForm InfoIDnumber=002
TicketInfoForm IDnumber=003 > TicketOutageForm InfoIDnumber=003
 
it entirely depends on how the data is sorted. the only tough part here is locating the record in the table, which depends on the method of search technique, which in turn depends on the sort order of the table!
 
I know where all the tables and fields are. I am trying to make a trouble ticket/system outage database. I will have an entry every day with daily info and the days ID number. I want to fill in the Day ID number into the outage table automatically base of the last created day ID Number. So if i have 3 outages in one day it will still use the same Day ID number. Not every day will have outage to report and some days might have 20+ outages to report.
 
I know where all the tables and fields are. I am trying to make a trouble ticket/system outage database. I will have an entry every day with daily info and the days ID number. I want to fill in the Day ID number into the outage table automatically based off of the last created day ID Number. So if i have 3 outages in one day it will still use the same Day ID number. Not every day will have outage to report and some days might have 20+ outages to report.
 
well that shouldn't be a problem then. Just use the DMAX() function in a recordset, or in the control source of the form's control, and then add one (+1) to it.
 

Users who are viewing this thread

Back
Top Bottom