Results 1 to 8 of 8
  1. #1
    rjgriffin46 is offline Competent Performer
    Windows 7 32bit Access 2010 32bit
    Join Date
    Apr 2014
    Location
    New Jersey
    Posts
    128

    Requery Error when Entering Design View for a Form

    As indicated in prior posts, I am modifying the Students template for a student & alumni administration database for our non-profit Food Service Training Academy.



    After making some changes recently, whenever I select Design View on a specific form (Student Details), a window pops up stating "The command or action 'Requery' isn't available now. The window further states that:
    • You may be in a read-only database or an unconverted database from an earlier version of the database
    • The type of object the action applies to isn't currently selected or isn't in the active view.
    • And finally "Use only those commands and macro actions that are currently available for this database."


    After exiting this window, a Macro Single Step window opens with the following info:
    • Macro Name: Student List : txtOpen : Onclick : Embedded Macro
    • Condition: (blank)
    • Action Name: Requery
    • Arguments: (blank)
    • Error Number: 2046


    This form is usually opened via an "Open" button in a list of students form called Student List. It has 5 tabs on it, the last I created & copied 2 queries to it. The form opens in Form view OK and I can switch to Layout view OK. Once in Design view I seem to be able to do go back and forth OK, although often going back into Design view sometimes only the name of the sub-form is displayed and the whole header, detail, grid, and controls etc. do not show.

    Further, you can open the Student Details form directly, but now it opens as a datasheet instead of a form. Otherwise, the normal use of the forms, from a user perspective, does not seem to be affected.

    This may have begun after I opened the database in Access 2007. I have done all the development in Access 2010.

    Any suggestions as to cause and resolution would be appreciated.

  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,929
    Rebuilding the form might be easier than trying to find the cause. Could be corruption in which case the cause will never be found. But if the issue continues with a new form, then definitely something messed up. If you then still have issue and want to provide db for analysis, 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
    ranman256's Avatar
    ranman256 is offline VIP
    Windows Vista Access 2010 32bit
    Join Date
    Apr 2014
    Location
    Kentucky
    Posts
    9,525
    Did you go to the code and do a find (Ctl-F) on 'Requery' to find the culprit?
    Last edited by June7; 06-12-2014 at 12:15 PM.

  4. #4
    rjgriffin46 is offline Competent Performer
    Windows 7 32bit Access 2010 32bit
    Join Date
    Apr 2014
    Location
    New Jersey
    Posts
    128
    I'm not sure where the code is.

  5. #5
    June7's Avatar
    June7 is offline VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,929
    You don't know how to open the VBA code editor?

    Of course, if you are using macros and don't have any VBA code, a search in VBA editor is not relevant.
    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.

  6. #6
    rjgriffin46 is offline Competent Performer
    Windows 7 32bit Access 2010 32bit
    Join Date
    Apr 2014
    Location
    New Jersey
    Posts
    128
    I think I found the Macro, but I am not sure what to make of it. It appears to open a form from a cell on a row of another form. I don't seem to be able to copy it. If you are interested, I could paste screen copies into a spreadsheet and attach to this post.

    Thanks

  7. #7
    Xipooo's Avatar
    Xipooo is offline Sr. Database Developer
    Windows 8 Access 2013
    Join Date
    Jan 2014
    Location
    Arizona
    Posts
    332
    Sounds to me like a requery call is running when the form closing or unloading event is being called.

  8. #8
    June7's Avatar
    June7 is offline VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,929
    Or could 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.

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

Similar Threads

  1. Replies: 6
    Last Post: 05-09-2014, 09:03 AM
  2. Replies: 1
    Last Post: 12-19-2013, 02:55 PM
  3. Replies: 1
    Last Post: 10-22-2013, 07:53 PM
  4. Replies: 8
    Last Post: 04-29-2013, 11:23 AM
  5. Replies: 5
    Last Post: 12-22-2011, 01:12 PM

Tags for this Thread

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