dada display from query

  • Thread starter Thread starter Rani
  • Start date Start date
R

Rani

I wrote a query based on a query filtered by the value of an unbound combo
box, the form is a continues form, displaying all the relevant lines of info
for a particular salesperson.
while running a requery, the form still display the data base on the
previous query.
any idea ?
 
If you're changing the records/values in the data source after a form has
opened, you'll need to requery that data source for the form to display any
new/changed data.
-Ed
 
that's what i am doing
on the unbound combobox
i have and afterupdate event
me.requery
yet the old data isn't eliminated from the form
just the additional lines (if exist) are being added
 
Not sure what you're using the combobox for, but typically on a continuous
style form, a combobox in the form header would be used as a "locator" to
select a particular record. Below is an example:

Private Sub Locate_AfterUpdate()
' Find the record that matches the control.
Dim rs As Object

Set rs = Me.Recordset.Clone
rs.FindFirst "[ID] = " & Str(Nz(Me![Locate], 0))
If Not rs.EOF Then Me.Bookmark = rs.Bookmark
Me![Name].SetFocus
[Locate].Value = Null

End Sub

Another typical setup is to use a single record form as a Main form, then a
related child Sub form (as continuous or datasheet) to show related info.

A "Refresh" or "Show All Records" command should display the filtered
records.
-Ed
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top