how do I make forms interactive?

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

Guest

I'm trying to create a form which is a culmination of several tables and
queries that you can check certain boxes and it will effect the table that it
originates (for example, if a box is checked, it adds today's date to a table
or query, as well as a value for the checked box). I'm coming across several
problem with this...

1. My form is not interactive. You cannot check a box on the form or select
an item on a drop down list. My form is not read-only and the objects are all
bound. Am I just building it incorrectly, or telling the information to do
the wrong thing? Should I have the box bound to a blank table and when the
box is checked, it will take all the information and add it to the table? I
tried searching the help and my Access Bible, but I don't even know where to
begin to look for that...

2. Does the Date() function always keep the same date when in use, or can I
have it so, as above, if you select the check box, it will show the date that
the box was selected?

I'm sure I will have more questions, but those will all be posted
seperately...
 
Stephanie,

See my responses below for each section.

Stephanie Gordon said:
I'm trying to create a form which is a culmination of several tables and
queries that you can check certain boxes and it will effect the table that it
originates (for example, if a box is checked, it adds today's date to a table
or query, as well as a value for the checked box). I'm coming across several
problem with this...

1. My form is not interactive. You cannot check a box on the form or select
an item on a drop down list.

As a form's RecordSource becomes more complex, it is more and more likely
that the query becomes non-updateable. There are many potential causes for
this, Google will find some. This is not normally a limitation, because you
can display informational fields from another table by using the Column
property of a combo box. For example, let's say you are entering a Customer
Number into an Orders table, and wish to display the customer name, address,
phone, and other fields on the form. If you include these fields in the
RowSource of the combo box, you can display anyone of them in a textbox by
setting the ControlSource to:

=[MyComboBox].Column(index), where index is the column #, starting with zero.
My form is not read-only and the objects are all
bound. Am I just building it incorrectly, or telling the information to do
the wrong thing? Should I have the box bound to a blank table and when the
box is checked, it will take all the information and add it to the table? I
tried searching the help and my Access Bible, but I don't even know where to
begin to look for that...
Normally, data entry is most straight-forward by binding the form to a table
or updatable query, and binding the controls to fields in the recordset.
There are cases, depending on what you're trying to do, that you might wish
to run an Insert or Update query that uses values entered in an Unbound form.
To advise you, please post more detail about the form and underlying query.
2. Does the Date() function always keep the same date when in use, or can I
have it so, as above, if you select the check box, it will show the date that
the box was selected?

The Date() function returns the current system date. To keep a date, you
would need a Date-type field in the RecordSource, and code to set it when the
user clicks your checkbox, like:

If Me![MyCheckBox] = True Then
Me![MyDateField] = Date()
Else
Me![MyDateField] = Null
End If
I'm sure I will have more questions, but those will all be posted
seperately...

I strongly suspect that your tables are not normalized. Please post your
table structures, and a generic description of what your application is
designed to do, and I'm sure we can help steer you in the right direction.

Hope that helps.
Sprinks
 
Back
Top