Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsFormsForms ProgrammingQueriesModules / DAO / VBAReports / PrintingMacrosDatabase DesignSecurityConversionImporting / LinkingSQL Server / ADPMultiuser / NetworkingReplicationSetup / ConfigurationDeveloper ToolkitsActiveX ControlsNew UsersGeneral 1General 2
Access DirectoryToolsTutorialsUser Groups
Related Topics
SQL ServerOther DB ProductsMS OfficeMore Topics ...

MS Access Forum / Modules / DAO / VBA / February 2005

Tip: Looking for answers? Try searching our database.

Move cursor to a specified field

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Marv Keane - 27 Feb 2005 14:53 GMT
Does anyone have any sample code on how I can move the cursor to a specified
field on an Access form when a certain criteria is met on a subform?

Thanks in advance.
'69 Camaro - 27 Feb 2005 15:07 GMT
Hi, Marv.

To move the location of the cursor from a subform to another form that is
currently open (even if it's not the form that contains the subform in
question), try:

  If (certain_criteria) Then
      Forms("frmMain").txtMyField.SetFocus
  End If

... where "frmMain" is the form that has "txtMyField," the specific text box
where you want the user to type the next entry.

HTH.

Gunny

See http://www.QBuilt.com for all your database needs.
See http://www.Access.QBuilt.com for Microsoft Access tips.

(Please remove ZERO_SPAM from my reply E-mail address, so that a message
will be forwarded to me.)

- - -
When you see correct answers to your question, please sign in to Microsoft's
Online Community and mark these posts, so that all may benefit by filtering
on "Answered questions" and quickly finding the right answers to similar
questions.

> Does anyone have any sample code on how I can move the cursor to a specified
> field on an Access form when a certain criteria is met on a subform?
>
> Thanks in advance.
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.