Question Access 2010 RT crashes on Access 2016 machine (1 Viewer)

Tiger955

Registered User.
Local time
Today, 16:17
Joined
Sep 13, 2013
Messages
140
Without giving notice an administrator changed from Win 7 64 bit with Office 2010 32 bit to Win 10 64 bit with Office 2016 32 bit on a certain machine.

Now, our production database application based on Access 2010 Runtime 32 bit does not work anymore, ALTHOUGH I installed the neccessary runtime and let the application start with A2010 RT.
The app crashes with an error message when trying to open a certain form, but the code was compiled of course and has been running unchanged for many years on the old environment.


Another form crashed with error message after it is opened.


The code in the frmKunden is:
Code:
Private Sub Form_Open(Cancel As Integer) 
On Error Resume Next 
 'bei ungültiger Lizenz keine Eingabe möglich 
If Date > TempVars!licencedate Then 
MsgBox "Lizenz für die Nutzung des Programms abgelaufen!" & vbCrLf & "Sie    können Daten ansehen, aber keine verändern oder neue hinzufügen!",   vbCritical, "Kontaktieren Sie Ihren Softwarebetreuer!" 
Me.AllowAdditions = False 
Me.AllowDeletions = False 
Me.AllowEdits = False 
End If  
End Sub
TempVars!licencedate is for example 31.12.2017 but when trying

Code:
If Date < TempVars!licencedate
I get NO error in the developer machine (On error Resume next turned off!) but the message box, so Date is comparable with 31.12.2017.


Next code is:
Code:
Private Sub Form_Current() 
Dim ctl As Control 
On Error Resume Next 
If Not IsNull(Me.Firma) Then     
Me.KopfName = Me.Firma & " / " & (Me.Vorname + " ") & " " & Format(Me.[Nachname], ">") 
Else     
Me.KopfName = (Me.Vorname + " ") & " " & Format(Me.[Nachname], ">") 
End If  

If Me.NewRecord Then     
For Each ctl In Me.Controls        
  If ctl.Tag = "x" Then 'Or  'Pflichtfeld            
      ctl.Locked = False         
  End If     
Next ctl 
Else     
  For Each ctl In Me.Controls        
    If ctl.Tag = "x" Then 'Or  'Pflichtfeld 
           ctl.Locked = True   
     End If     
Next ctl 
End If 

Me.Bestellungsübersicht.Form!SumPreis = Nz(DSum("SummePosition", "vwWSBestellungsDetails", "([BestellID]=" & Me.Bestellungsübersicht.Form!BestellID & ")"), Null)
 Me.Bestellungsübersicht.Form!SumAnz = Nz(DSum("Anzahl", "vwWSBestellungsDetails", "([BestellID]=" & Me.Bestellungsübersicht.Form!BestellID & ")"), Null)  

End Sub
I checked all references, if they are available and not broken (IsBroken = false), but cannot find the cause for the Runtime error which determins the program.

Any other ideas to detect and solve the problem??

I tried to open the accdb (version Access 2010) in Access 2016 full version but could not even find HOW to get into Visual Basic editor. (owfull Access 2016!!). Can someone help - PLEASE!

Thx Michael
 

The_Doc_Man

Immoderate Moderator
Staff member
Local time
Today, 09:17
Joined
Feb 28, 2001
Messages
27,322
You say it crashes with an error message. It would be nice to know WHICH error message.
 

Tiger955

Registered User.
Local time
Today, 16:17
Joined
Sep 13, 2013
Messages
140
You say it crashes with an error message. It would be nice to know WHICH error message.

I am sorry, you are right:
But the message is absolutely MEANINGLESS.

It says "Execution of this application has stopped due to a run-time error. The application can't continue and will be shut down."
Nothing more.

Thats why I cannot continue searching as I have no glue where it could come from.
I will try to run another version without any error handler, maybe something pops up.!
Michael
 

Tiger955

Registered User.
Local time
Today, 16:17
Joined
Sep 13, 2013
Messages
140
Randomly I have a trace what causes the crashes, although I have no clue why:

In my forms (which crashes) I have tabs (pages).
Whenever a "main record" has linked records from another table, displayed in the tabs, the app crashes.

Whenever I delete the related records in the other table I can scroll through the form as long as a main record has "child records" in another table, the it crashes again!!

I have never before made this experience and so I do not have any idea, where is comes from and why it happens.

Whats going wrong on this machine (windows 10 64 bit, Access 2010 RT 32 bit).
Thx Michael
 

Frothingslosh

Premier Pale Stale Ale
Local time
Today, 10:17
Joined
Oct 17, 2012
Messages
3,276
This is a common error when running an accdb file on A2013 or later and then on A2010 or earlier.

Basically, the newer version of Access updates the references in the VBA Editor to their 2013/2016 equivalents, but the older one is unable to revert them back.

I would advise opening the app in A2010, going into the VBA editor (Alt-F11 should work in both versions as long as a form is open), and looking for references marked as missing. If you see any, then that's what happened and you'll need to deactivate them, manually find the correct ones, and reactivate them.

And then implement an ironbound rule that A2013 and later get their own copies distinct from A2010 and earlier, and each app is only allowed to open the matching database. Otherwise, you're going to run into this error CONSTANTLY.
 

Frothingslosh

Premier Pale Stale Ale
Local time
Today, 10:17
Joined
Oct 17, 2012
Messages
3,276
And the reason you're getting good references but not being able to run sounds like you're EDITING the file in A2016, but RUNNING it under A2010. That just doesn't work because of this damned bug.
 

Tiger955

Registered User.
Local time
Today, 16:17
Joined
Sep 13, 2013
Messages
140
I found the error!
It had nothing to do with any versions 2010 or 2016.

I changed a field in a SQL table from "Null" to "not Null", but did not refresh the links in Access accdb and did therefore not create a new accde.

Although there where NO orphan records in the child table, there has been any bad influence in Access which caused the crashes.

As obviously no user tried to enter data into this tab (page) the error did not pop up earlier.
Due to the changes in OS and Access version some might have tried it again and the error was detected. Too many changes at the same time gave me the wrong direction of error searching.

It seems like I solved it now, as it runs stabile now.

Michael
 

Users who are viewing this thread

Top Bottom