Free Lessons
Courses
Seminars
TechHelp
Fast Tips
Templates
Topic Index
Forum
ABCD
 
Home   Courses   TechHelp   Forums   Help   Contact   Merch   Join   Order   Logon  
 
Back to Access Forum    Comments List
Upload Images   @Reply   Bookmark    Link   Email   Next Unseen 
Update a Form That is Using an Aggregate Query
Joseph Bergman 
     
13 months ago
I have a Continuous Form that I only need to be able to update two Boolean fields. I have some data that is being summed from other tables I was using DSum as the business is growing that is getting to slow. So now I changed Record Source and used an aggerate query to get the data much faster. I knew this was gonna change the form so I could not update it. I thought I would have been able to use a on click event then to  either  run a recordset or  a sql update statement to update it however it wont even run a on Click event. The solution I came up with right now is to use a button on top of the check boxes and set it to transparent. I was wondering if there is a better way? Also would it be better to use a Recordset or a SQL statement? Why wont an "On Click" event work?

this is the code I am using now
Dim blnTF As Boolean
If Me.Closed = True Then
    blnTF = False
Else
    blnTF = True
End If

Dim mysql As String
    mysql = "UPDATE JobT SET closed=" & blnTF & " Where JobID =" & Me.JobID
    DoCmd.SetWarnings False
    DoCmd.RunSql mysql
    DoCmd.SetWarnings True
    Me.Recordset.Requery

This thread is now CLOSED. If you wish to comment, start a NEW discussion in Access Forum.
 

Next Unseen

 
New Feature: Comment Live View
 
 

The following is a paid advertisement
Computer Learning Zone is not responsible for any content shown or offers made by these ads.
 

Learn
 
Access - index
Excel - index
Word - index
Windows - index
PowerPoint - index
Photoshop - index
Visual Basic - index
ASP - index
Seminars
More...
Customers
 
Login
My Account
My Courses
Lost Password
Memberships
Student Databases
Change Email
Info
 
Latest News
New Releases
User Forums
Topic Glossary
Tips & Tricks
Search The Site
Code Vault
Collapse Menus
Help
 
Customer Support
Web Site Tour
FAQs
TechHelp
Consulting Services
About
 
Background
Testimonials
Jobs
Affiliate Program
Richard Rost
Free Lessons
Mailing List
PCResale.NET
Order
 
Video Tutorials
Handbooks
Memberships
Learning Connection
Idiot's Guide to Excel
Volume Discounts
Payment Info
Shipping
Terms of Sale
Contact
 
Contact Info
Support Policy
Mailing Address
Phone Number
Fax Number
Course Survey
Email Richard
[email protected]
Blog RSS Feed    YouTube Channel

LinkedIn
Copyright 2026 by Computer Learning Zone, Amicron, and Richard Rost. All Rights Reserved. Current Time: 6/21/2026 5:16:50 PM. PLT: 0s