Pls help with form

T

TotallyConfused

I have query make table. I am trying to create a form that will run this
query. However, for this query to run I also need to filter dates from a
date field. eg: between #01/01/2008# and #01/31/2008#.

First, of all the query make table does not come up in control source for
form. Why? Second, how do I bind my text box to the same date field? Can I
use two text boxes? One for the 1st date and second text box for second
date? Is there an example. Kinda of rusty as I have not been using Access
lately.
Can you please help me with this? Thank you in advance.
 
J

John W. Vinson/MVP

TotallyConfused said:
I have query make table.

Ummm... why?

MakeTable queries are VERY rarely needed. If you need to display records on
a Form or Report, or export them, or base a query on them, you can use a
Select Query; it's rarely necessary to create a new table. What will this
table be used for?
I am trying to create a form that will run this
query. However, for this query to run I also need to filter dates from a
date field. eg: between #01/01/2008# and #01/31/2008#.

First, of all the query make table does not come up in control source for
form. Why?

Because a MakeTable query does not return any records. It performs an
action, but it cannot be used as the recordsource for a form (forms don't
have Control Source).
Second, how do I bind my text box to the same date field? Can I
use two text boxes? One for the 1st date and second text box for second
date? Is there an example. Kinda of rusty as I have not been using
Access
lately.

You can create a MakeTable query using
= [Forms]![YourFormName]![txtStart] AND <= [Forms]![YourFormName]![txtEnd]

as a criterion.
Can you please help me with this? Thank you in advance.

Perhaps you could explain what you are trying to accomplish in the real
world - there's almost surely a better approach.
 

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

Top