Results 1 to 9 of 9
  1. #1
    lissaru is offline Novice
    Windows 7 64bit Access 2013 64bit
    Join Date
    Mar 2016
    Posts
    5

    the action will reset the current code in break mode error

    I have an Access mdb format split database. There are main form and pop-up subform.
    When I click on ID in main form pop-up subform appearing. This subform has several buttons i.e. to exit form without saving and 1 to save edits. (Save Edits, Cancel, Exit).
    The problem is:
    When I filter records in main form i.e by a certain ID, then I click on ID and a subform pops-up. Then I click i.e. on Cancel (or on Exit), subform closing fine and brings me to the main form. Which is Correct!

    However, when I filter by certain fields such as CreatedBy, CreatedOn, Type, Year (for now only these fields) then open the subform and click on Cancel, Exit, or Save Edits, a warning message appearing "the action will reset the current code in break mode". If I click Yes, nothing is happening, If I click No, the subform closing and brings me to the main form as well.

    I think it might be data corruption (not database corruption).



    I have tried decompile database:
    https://www.fmsinc.com/microsoftacce.../Decompile.asp

  2. #2
    NTC is offline VIP
    Windows 7 64bit Access 2013
    Join Date
    Nov 2009
    Posts
    2,392
    first to clarify terminology: "subform pops-up" is contradictory. A subform is, by definition, inset into a main form. I will assume you have a form that is set to be a pop up property. This pop up typically is modal, meaning you can't do anything else until the pop up form is closed. This filtering and modal may be at odds -though it is unclear to me as to why....but if there is vba code involved in any of the events being fired that could be creating this issue. If the issue is not due to vba code then you might re-option the pop up form property to not be modal. That may make a difference. Although probably not an issue - the fact that it is now a relatively old file format means that finding a work around / solution is getting harder to do so also as a test you might convert the file to the current accdb format and see if that has any affect on things....but I believe it to be low probability....

  3. #3
    lissaru is offline Novice
    Windows 7 64bit Access 2013 64bit
    Join Date
    Mar 2016
    Posts
    5
    Quote Originally Posted by NTC View Post
    first to clarify terminology: "subform pops-up" is contradictory. A subform is, by definition, inset into a main form. I will assume you have a form that is set to be a pop up property. This pop up typically is modal, meaning you can't do anything else until the pop up form is closed. This filtering and modal may be at odds -though it is unclear to me as to why....but if there is vba code involved in any of the events being fired that could be creating this issue. If the issue is not due to vba code then you might re-option the pop up form property to not be modal. That may make a difference. Although probably not an issue - the fact that it is now a relatively old file format means that finding a work around / solution is getting harder to do so also as a test you might convert the file to the current accdb format and see if that has any affect on things....but I believe it to be low probability....
    I have tried to transfer to .accdb format, same issue. Yes, I have vba code involved in this database; however, it should not be a cause of the filtering issue because vba used for other options. To open the pop-up form I have a macro for ID field (that opens selected record). pop-up form is modal, the main form is not. I can not understand why this issue is only with some fields filtering, not with all. To be able to filter I have just simple filtering option (in the main form properties - Allow Filtering: Yes). What might be wrong with filtering? I really need your help to find the solution. Thank you

  4. #4
    NTC is offline VIP
    Windows 7 64bit Access 2013
    Join Date
    Nov 2009
    Posts
    2,392
    I am not sure. Test the pop up form as not modal - just to see if it changes the behavior. The only thing beyond that is code that is firing somewhere with the pop up form actions - -

    ... I do not recognize the warning message either .... it is not clear if the error is due to data itself or the process/sequence of coding.

    at some point one must break it down to very small steps to test each step individually - - or potentially create a new test pop up form for comparison

  5. #5
    lissaru is offline Novice
    Windows 7 64bit Access 2013 64bit
    Join Date
    Mar 2016
    Posts
    5
    Quote Originally Posted by NTC View Post
    I am not sure. Test the pop up form as not modal - just to see if it changes the behavior. The only thing beyond that is code that is firing somewhere with the pop up form actions - -

    ... I do not recognize the warning message either .... it is not clear if the error is due to data itself or the process/sequence of coding.

    at some point one must break it down to very small steps to test each step individually - - or potentially create a new test pop up form for comparison
    I think if it was a code issue, using all filters would lead to this problem.
    I have tested the pop-up form as not modal - same thing.
    I just can not understand how the code might be involved to get this issue...for Cancel and Exit buttons - there simple codes. For Save and Close - macro used with queries. And, again, if i filter data by other fields (except Year, CreatedBy, CreatedOn, Type) all these buttons work perfectly. So, that's why I don't see the code issue here.
    Also, I have created new pop-up form, same thing.
    Last edited by lissaru; 03-09-2016 at 04:00 PM.

  6. #6
    NTC is offline VIP
    Windows 7 64bit Access 2013
    Join Date
    Nov 2009
    Posts
    2,392
    it could be the data itself; typically a data caused scenario is where there is a null/blank in the data set that causes problem with code not written to deal with a null non value.

    otherwise on this one you have me stumped at the moment.

  7. #7
    lissaru is offline Novice
    Windows 7 64bit Access 2013 64bit
    Join Date
    Mar 2016
    Posts
    5
    Quote Originally Posted by NTC View Post
    it could be the data itself; typically a data caused scenario is where there is a null/blank in the data set that causes problem with code not written to deal with a null non value.

    otherwise on this one you have me stumped at the moment.
    I decided to split database to parts based on year. Because I don't see another way to get read of this error message. Maybe access gets confused because of big amount of data. Also, the database built on queries (some of them built on other queries), macro, vba codes.

    About Null/blank data. I have two "Number" fields where by default set 0. However, this field contains not only zeros, there are some blanks. One field work fine, when user picks the value, it populates all other forms fine. Another field work weird, when user picks the value, it populates not all forms in a correct way. I.e. User has an option to mark a record as Deleted in the pop-up form (that we discussed previously). This record automatically goes to Deleted form, and when you open (clicking on ID as well) this record in Deleted form, this number field is flinching with <Error> (except if there is a NULL/blank value). So, I have tried to delete these two fields (this weird one and the second one just in case) i have got same error message. So, it means that "null/blank" doesn't lead to get this error in my case.
    After I have tried to split the database based on Year field, everything looks fine (at least for now) and user don't have to filter by Year, and also filtering by CreatedBy works fine as well.

    Probably, this is not the best way to solve the problem, but, unfortunately, I don't see any others..

    Thanks for your help. I will let you know if I will find another way, or if something will go wrong.

  8. #8
    NTC is offline VIP
    Windows 7 64bit Access 2013
    Join Date
    Nov 2009
    Posts
    2,392
    Maybe access gets confused because of big amount of data.
    ** this is never the case - within the 2G file size limit - and is an issue of the power of the PC in terms of RAM typically

    Also, the database built on queries (some of them built on other queries), macro, vba codes.
    ** again - this is common so would not be an issue

    That you have split the data into years and eliminated the error: but you have also thereby eliminated the need to filter by year: so you definitely have advanced to understanding the issue. It is very interesting. I wonder is it the year data filter itself? the data in the year field?.. or is there a maximum number of filters that is causing the error....and since you no longer need to filter by year then you no longer reach that filter maximum?

    I can understand that you do not have time to follow this further if you have found a fix. I do know there is a filter maximum though off hand I can't remember the count and have never thought of it to throw an error like this but it seems possible.....but then again it could still be the data in that field too...

  9. #9
    lissaru is offline Novice
    Windows 7 64bit Access 2013 64bit
    Join Date
    Mar 2016
    Posts
    5
    Quote Originally Posted by NTC View Post
    Maybe access gets confused because of big amount of data.
    ** this is never the case - within the 2G file size limit - and is an issue of the power of the PC in terms of RAM typically

    Also, the database built on queries (some of them built on other queries), macro, vba codes.
    ** again - this is common so would not be an issue

    That you have split the data into years and eliminated the error: but you have also thereby eliminated the need to filter by year: so you definitely have advanced to understanding the issue. It is very interesting. I wonder is it the year data filter itself? the data in the year field?.. or is there a maximum number of filters that is causing the error....and since you no longer need to filter by year then you no longer reach that filter maximum?

    I can understand that you do not have time to follow this further if you have found a fix. I do know there is a filter maximum though off hand I can't remember the count and have never thought of it to throw an error like this but it seems possible.....but then again it could still be the data in that field too...

    I found another solution.
    I deleted those two number fields (that had own tables with IDs). Created 2 new text fields (and two new tables without IDs) as combo boxes with drop down menu that allows the users pick the option if necessary. Also, I have changed the properties of the main form: Data tab - Fetch Default - No, Filter On Load - No, Order on Load - No. For the pop-up form set: Data tab - Fetch Default - No , Filter On Load - Yes, Order on Load - Yes.
    For now, there are no errors appearing.
    I have noticed that when I had settings for the main form i.e. Data tab - Fetch Default - Yes, Filter On Load - No, Order on Load - Yes, the application populates the Filter On Load and Order on Load values in properties and gives me that error again once I open another record's pop-up window. However, when I set all to No, there is only Filter On Load populated in properties but I don't get any errors after.
    So, I think the problem was in properties settings, and with those number fields (because I got <Error> in other forms for one of the number fields, now everything works correctly).

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

Similar Threads

  1. Code runs in break/debug mode but not in normal mode
    By hansendl in forum Programming
    Replies: 2
    Last Post: 10-15-2014, 07:23 AM
  2. Replies: 4
    Last Post: 11-26-2013, 10:47 AM
  3. Asc/Desc/reset sort button code
    By mightyteegar in forum Programming
    Replies: 2
    Last Post: 10-30-2012, 04:24 PM
  4. Replies: 8
    Last Post: 01-17-2012, 02:43 PM
  5. Word code in Access - How to modify my current code
    By Alexandre Cote in forum Programming
    Replies: 0
    Last Post: 11-15-2010, 08:26 AM

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