Results 1 to 3 of 3
  1. #1
    SGrohola is offline Advanced Beginner
    Windows 10 Access 2013 32bit
    Join Date
    Mar 2017
    Location
    Romulus, MI
    Posts
    41

    Question Getting error when trying to search on last name

    I have a main form which has owner/operators listed in it. In my main form, I have several buttons with subforms, to add information to the owner/operator.



    When I open the main form, search on a last name, and then click on a button to add the address or HR information, I have no problems. BUT, when I open my form, and make any changes to the main data (like update the phone number), and then try to search on another owner/operator (I have a button set up with a macro, to go to last name and then bring up search), I get an error, and then it forces me to close the form, and tells me that it can not save the data (even though it has saved the data). I have tried adding a "save" button to the main form, and when I click on that, a box pops open with nothing but an "OK" button to click, and I'm not sure if it's saving the form. I tried adding a "save and refresh" button, but again, if I make any changes to the data on the main form, and try to click button, I get an error (Error number 2950).

    All I want to be able to do, is open the form, add or update the data on main form, and then have it "save" or "refresh" the data, so that the sub-data forms can be opened and updated as well, and all is good.

    If this is confusing, it's confusing for me as well. I truly don't understand why the data is just not saving when I click the "save" button.

    I have zipped the databases as that is the only way it would let me upload it to this.
    Attached Files Attached Files

  2. #2
    davegri's Avatar
    davegri is online now Excess Access
    Windows 10 Access 2016
    Join Date
    May 2012
    Location
    Denver
    Posts
    3,405
    frmMain1, event after_update uses a macro to update [Date Modified].
    Makes no sense to update again after update..., it locks up the form.
    Change it to before_update.

    Probably the reason you're getting slow responses is because of your heavy use of macros. Few people here use them, including me. VBA is the code of choice here and with most serious developers.

  3. #3
    SGrohola is offline Advanced Beginner
    Windows 10 Access 2013 32bit
    Join Date
    Mar 2017
    Location
    Romulus, MI
    Posts
    41
    Thanks! That seems to be what the problem was. I was ready to throw out my laptop yesterday. I'm not a programmer, never claimed to be, but I have done a few databases over the years.... it's been 6 years since my last one, and trying to get back into the swing of things has definitely taken it's toll on me. I just want to have this done and pass it to the dept that will use it.




    [QUOTE=davegri;352266]frmMain1, event after_update uses a macro to update [Date Modified].
    Makes no sense to update again after update..., it locks up the form.
    Change it to before_update.

    Probably the reason you're getting slow responses is because of your heavy use of macros. Few people here use them, including me. VBA is the code of choice here and with most serious developers.[/QUO

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

Similar Threads

  1. Search Form Error
    By N7925Y in forum Programming
    Replies: 3
    Last Post: 10-21-2016, 10:25 AM
  2. Search Combo Box Error
    By jon84dwk in forum Forms
    Replies: 1
    Last Post: 08-29-2016, 02:15 PM
  3. Replies: 6
    Last Post: 09-22-2015, 03:30 PM
  4. Replies: 4
    Last Post: 04-21-2015, 07:12 PM
  5. Search Criteria Error
    By hitesh_asrani_j in forum Forms
    Replies: 25
    Last Post: 09-29-2011, 10:35 AM

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