Multi-Query enter date based on checkbox

S

Sean Timmons

So, I have a form with about 50 checkboxes as well as combo boxes for sup
name, rep name, date.

I would like to set a query or some such thing that will set the underlying
fields to the selected date for any items that are checked.

So, if items 1, 5 and 8 are checked, but the rest are unchecked, the table
will show the selected date in fields 1, 5 and 8, and blank in 2,3,4, etc.

I'll do this on mouse down, build a command button, or whatever makes it
easiest...

Any thoughts?
 
J

John W. Vinson

So, I have a form with about 50 checkboxes as well as combo boxes for sup
name, rep name, date.

I would like to set a query or some such thing that will set the underlying
fields to the selected date for any items that are checked.

So, if items 1, 5 and 8 are checked, but the rest are unchecked, the table
will show the selected date in fields 1, 5 and 8, and blank in 2,3,4, etc.

I'll do this on mouse down, build a command button, or whatever makes it
easiest...

Any thoughts?

Well, a command button... but I've got to say that if you have fifty date
fields controlled by checkboxes, that your table design IS WRONG. If you have
a one (something) to many (dates) relationship, you'll be MUCH better off
structuring it as a one to many relationship with a second table; this table
would have a link to your current table, a field identifying what kind of date
it is (based on the labels of your fifty checkboxes), and a datefield.

Your current structure will get you in no end of trouble as your development
continues - searching for dates will be difficult, adding or deleting a field
will require rebuilding all your queries, forms, and reports... OUCH!
 

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