Generating a new text box

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I am creating a database to track employee issues. Ideally, I would like to
create a text box to record a summary of the issue, resolution and date of
call. I would like to set the form up so that it displays only one of these
boxes, but will automatically generate a new box and move the old entries to
the bottom of the list. This way, the history can be kept in chronological
order, with the most recent entry showing first.

I worked on this type of database in a past life, but don't know how it was
created. Has anyone created or worked with something similar?
 
First, you need the text field to be a Memo because Text is limited to 255
characters.
Create a main form with the information you want to add. Make its Data entry
property "Yes"
Create a query of the table where your data is stored and sort it in
Descending order.
Create a subform (Continuous) based on this query and place it directly below
the fields on your main form.
Place the following code in the After update property of the last field of
the main form:
Private Sub Command1_Click()

DoCmd.DoMenuItem acFormBar, acRecordsMenu, 5, , acMenuVer70
DoCmd.GoToRecord , , acNewRec

End Sub
The first DoCmd does a Refresh so the query will pick up the record and the
second goes to a new record
Hope this helps,
 
Back
Top