Select Form and detail

  • Thread starter Thread starter SAC
  • Start date Start date
S

SAC

Access 2000

I'd like to make a data sheet form showing a listing of jobs and when one is
selected, then the detail of that job shows in a single record view form in
the lower portion of the screen.

Can you give me a little direction on this?

Thanks.
 
I would suggest a side by side type of arrangement. (but, what you want is
certainly do-able).

Take a look at the following screen shot:

http://www.attcanada.net/~kallal.msn/Articles/Grid.htm

In your case, the details is going to be just a sub-form. So, the "list" can
either be a another sub-form, or as in the screen shots above, a listbox.

The code in the after update event of the list box can be:

If IsNull(Me.MyListBox) = False Then
If Me.MyListBox <> "" Then
subSql = "SELECT * from tblCustomer where WHERE [ID] = " &
Me.MyListBox
me.MySubForm.Form.RecordSource = subSql
End If
End If


Albert D. Kallal
Edmonton, Alberta Canada
(e-mail address removed)
 
I'm using the list for showing the records and the single record form for
data entry.

How do I refresh the list when I added or changed a record without adding an
unwanted record to the table?

Thanks.
 
Back
Top