473,386 Members | 1,702 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

Update a field when a checkbox is clicked

Hello

I'm getting stumped and this is probably Access 101 but here goes.

I have a list of To_do's When I click on a checkbox "Complete" I want
automation to update a field called "Completed Date" to be updated
with the current date.

Please share with me the best way to do this. I have tried to do this
in VBA but I have not been able to correctly use the table and field
names to give it a value.

Thanks

Norris

x-- 100 Proof News - http://www.100ProofNews.com
x-- 3,500+ Binary NewsGroups, and over 90,000 other groups
x-- Access to over 800 Gigs/Day - $8.95/Month
x-- UNLIMITED DOWNLOAD

Nov 12 '05 #1
1 1985
"N. Graves" wrote
I have a list of To_do's When I click
on a checkbox "Complete" I want
automation to update a field called
"Completed Date" to be updated
with the current date.


I will assume your "list of To-do's" is, in fact, on a Form and that's where
the Checkbox is located. Put another TextBox on the Form, call it
txtCompletedDate, with a ControlSource of "Completed Date" and set its
Visible property to No. In the AfterUpdate event of the "Complete" checkbox,

Me!txtCompletedDate = Date() 'for Date only

or

Me!txtCompletedDate = Now() 'for both Date and Time

Larry Linson
Microsoft Access MVP
Nov 12 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Sue Adams | last post by:
I actually have two issues/questions: I have an autonumber field in an access db table that I grab and later use to update a record in another table withing the same db. The code I use to get...
1
by: Jim | last post by:
I have a 2 checkboxes and a hidden field..what I want to happen is that you can only click on 1 of these checkboxes at a time and when you check a checkbox it will assign the hidden field...
5
by: A.Dagostino | last post by:
hi i need to update an SQL Table when user select or unselect a checkbox control. How Can i do? Thanks Alex
0
by: Just D | last post by:
Hi All, Does anybody know how to write the following code? I have a database table with a few columns including: ID , "Task" , ForceRun . I need to show the DataGrid on the ASPX page with...
1
by: Wolffang | last post by:
From: "Wolffang" <javid@techlite.co.uk> Subject: How to do a multiple select and update in a datagrid Date: 23 October 2004 21:28 Using Visual studio.net VB I have a datagrid that brings...
2
by: Nu2ASP.NET | last post by:
What I am trying to do is essentially 'flip' the bits, when the user clicks in the checkbox. For example, if the CheckBox appears checked, and the user un-checks it, I want the underlying data...
0
by: Reena | last post by:
Hi, Working with ASP.NET 2.0 with Masterpages. Here is my datagrid... <asp:DataGrid ID="dgSelectedFields" runat="server" BorderStyle=None GridLines="None" CssClass="grdData"
16
by: Ian Davies | last post by:
Hello Needing help with a suitable solution. I have extracted records into a table under three columns 'category', 'comment' and share (the category column also holds the index no of the record...
1
by: hmlarson | last post by:
I have a form/table with checkboxes that I would like the user to check / uncheck if they want a certain record to display in a gallery on a website. I'm having problems figuring out how to...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.