Wrox Programmer Forums
Go Back   Wrox Programmer Forums > Microsoft Office > Access and Access VBA > Access VBA
|
Access VBA Discuss using VBA for Access programming.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Access VBA section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old October 29th, 2004, 04:10 PM
Authorized User
 
Join Date: Apr 2004
Posts: 45
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via MSN to lguzman
Default Query: getting criteria from a textbox in a form

I have created an action query (Update query), which I want to launch from a form. I have created two textboxes in that form, "Start" and "End". I would like the update query to use the information entered in these textboxes by the user, as its criteria. How do I do this? >="!FORMS!FORMNAME!TEXTBOXNAMESTART" and <="!FORMS!FORMNAME!TEXTBOXNAMEEND" ???????


HELP!!!





[LGuzman]
__________________
[LGuzman]
 
Old October 29th, 2004, 07:30 PM
Authorized User
 
Join Date: Oct 2004
Posts: 59
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Close, but no cigar.

>=[Forms]![Formname]![TextBoxNameStart]

You should also choose Parameters from the Query menu and explicitly define the parameter and its data type.



John Viescas, author
"Microsoft Office Access 2003 Inside Out"
"Running Microsoft Access 2000"
"SQL Queries for Mere Mortals"
 
Old November 1st, 2004, 10:16 AM
Authorized User
 
Join Date: Apr 2004
Posts: 45
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via MSN to lguzman
Default

Thank you!

[LGuzman]





Similar Threads
Thread Thread Starter Forum Replies Last Post
Ajax change textbox bgcolor after Criteria met mkthompson Ajax 1 July 28th, 2008 08:56 AM
Conditional criteria in query dfuas BOOK: Beginning Access VBA 0 January 15th, 2006 03:19 PM
Using a textbox as query criteria problem marcin2k Access VBA 5 March 30th, 2005 12:01 PM
Criteria in Query lryckman Access 1 June 23rd, 2004 11:11 AM
Query Criteria Clive Astley Access 4 March 25th, 2004 03:27 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.