Results 1 to 4 of 4
  1. #1
    Heatshiver is offline Competent Performer
    Windows 7 64bit Access 2010 64bit
    Join Date
    Dec 2011
    Posts
    128

    Question Find Button won't work if Data Entry = Yes

    I have a simple database that has one table, one query, one form, one report, and one switchboard (form).



    The query looks at all fields on the table and is the source for the form. The form adds new records to the table. The table populates the report. My primary key are dates. I have a Find button on the form that looks by a date.

    The issue I am having is that when I click the Find button (created with the Command Wizard) for the form, it comes up with the message "The command or action 'Find' isn't available now."

    I decided to go back to an older version of the DB I saved when the Find button was still working. I noticed that when I changed the form's Data Entry to Yes the Find button would then return the message above. If I changed the Data Entry back to No the Find button would work as expected.

    I need the Data Entry to be set to Yes so that it comes up blank when a user wants to input data, but I need the Find button to work in case they need to go back and edit an older record. Is there a simple way to fix this? OR a different manner to have the form come up blank, or a different method [using macros] to "find" a record?

    Thanks for the help.

    P.S.

    On my current version of the DB, changing the form's Data Entry back to No still has it display the error message above.

  2. #2
    June7's Avatar
    June7 is offline VIP
    Windows XP Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,931
    You could have the form open with all records but then goto a new record. Otherwise would need code in the Find button that resets the DataEntry property and requeries the form then does search, like:
    Me.DataEntry = False
    Me.Requery

    Regarding your P.S. - I just tested this and changing form's DataEntry back to No made the Find available. Something else must be happening.
    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
    Heatshiver is offline Competent Performer
    Windows 7 64bit Access 2010 64bit
    Join Date
    Dec 2011
    Posts
    128
    Thanks June7, but I actually don't think I can do the coding as I am not good in the visual basic editor (although I plan on getting into it soon as I used to do VB6).

    You did give me an idea though: Since my switchboard is just buttons with macros, I went ahead and added a GoToRecord macro for a new record. This worked.

    However, I am curious as to how I would input the coding you supplied, or point to somewhere that will show me if you give get a chance.

    Thanks.

  4. #4
    June7's Avatar
    June7 is offline VIP
    Windows XP Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,931
    On the Properties sheet for the button, on Events tab, in any event select [Event Procedure] then double-click the ellipses (...). This will take you to the VBA editor and will be in the procedure. Type desired code. If the event has [Embedded Macro] you can convert the macro to VBA procedure. Review this for starters http://office.microsoft.com/en-us/ac...001214213.aspx
    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: 1
    Last Post: 11-16-2011, 02:29 PM
  2. Replies: 5
    Last Post: 03-03-2011, 03:56 PM
  3. Customer Entry/Find Duplicate/Similar names
    By pkstormy in forum Code Repository
    Replies: 0
    Last Post: 08-27-2010, 09:20 PM
  4. Replies: 1
    Last Post: 07-27-2010, 02:27 PM
  5. Replies: 3
    Last Post: 06-04-2010, 12:47 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