reset fields in multiple records

V

Vandenee

Hi,

I have an application where I have defined a field (yes/no). In a form
this checkbox can on or off .
I would like to have a button in this form which will reset this field
for all the records.
Is this possible?
 
A

Al Campagna

Vandanee,
Use a button to run an Update Query. This sample Update query changes
the [TestYN] in tblCustomers to all True.

Private Sub cmdSetTestYNToTrue_Click
DoCmd.RunSql "UPDATE tblCustomers SET tblCustomers.TestYN = True;"
End Sub
--
hth
Al Campagna
Microsoft Access MVP
http://home.comcast.net/~cccsolutions/index.html
"Find a job that you love... and you'll never work a day in your life."
 
V

Vandenee

Vandanee,
Use a button to run an Update Query. This sample Update query changes
the [TestYN] in tblCustomers to all True.

Private Sub cmdSetTestYNToTrue_Click
DoCmd.RunSql "UPDATE tblCustomers SET tblCustomers.TestYN = True;"
End Sub
--
hth
Al Campagna
Microsoft Access MVPhttp://home.comcast.net/~cccsolutions/index.html
"Find a job that you love... and you'll never work a day in your life."




I have an application where I have defined a field (yes/no). In a form
this checkbox can on or off .
I would like to have a button in this form which will reset this field
for all the records.
Is this possible?- Tekst uit oorspronkelijk bericht niet weergeven -

- Tekst uit oorspronkelijk bericht weergeven -

Al,

Thanks for your suggestion, it did the job.

Michiel
 

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