Results 1 to 3 of 3
  1. #1
    EddieN1 is offline Competent Performer
    Windows XP Access 2007
    Join Date
    May 2011
    Posts
    313

    Requirements for SetFocus

    I'm trying to use SetFocus based on the value in another field and I'm getting a "... can't move the focus to the control..." error message. I know the target control must be enabled and visible, and it is, but what other properties must be set to set focus to it? Thanks, Eddie



    Okay, now it's getting weirder... if I hit debug on the debug window, then F5, the debug window appears again. However, if I do this again, it works as I expected it to... cursor is on the target control... maybe, I should add these steps to the User Manual... Help, Eddie

  2. #2
    June7's Avatar
    June7 is offline VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,930
    Would have to evaluate code. If you want to provide db, follow instructions at bottom of my post.
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  3. #3
    Missinglinq's Avatar
    Missinglinq is offline VIP
    Windows 7 64bit Access 2007
    Join Date
    May 2012
    Location
    Richmond (Virginia, not North Yorkshire!)
    Posts
    3,018
    Where, exactly, are you trying to execute this code? You cannot, for instance, use code in the BeforeUpdate event of one Control in order to Set Focus to another Control.

    Linq ;0)>
    The problem with making anything foolproof...is that fools are so darn ingenious!

    All posts/responses based on Access 2003/2007

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Requirements Template?
    By dspblues in forum Access
    Replies: 8
    Last Post: 08-05-2013, 05:31 AM
  2. Unique print requirements....
    By ChuckColeman1812 in forum Reports
    Replies: 1
    Last Post: 11-26-2012, 02:40 PM
  3. GCP requirements
    By wilbr73 in forum Access
    Replies: 1
    Last Post: 11-20-2012, 12:44 PM
  4. Query with Complicated Requirements
    By Briana in forum Queries
    Replies: 1
    Last Post: 06-13-2012, 08:05 PM
  5. Rules and Requirements in a Form
    By Kirsti in forum Forms
    Replies: 9
    Last Post: 02-01-2012, 06:37 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums