32 bit and 64 bit msAccess (1 Viewer)

patrickS

New member
Local time
Today, 11:43
Joined
Nov 22, 2020
Messages
4
I have a 32 bit msaccess database (2016), on various machines it runs on 32 bit access.

On one machine it runs on 64 bit access. herein sits the issue, I have declared the few API's as PTRSafe. I run the database from the 64 bit version of access complied in 32 bit and also try complied in the 64 bit version of access.

Now the issue, On a specific form (only one) that loads and runs perfectly in 32 bit, it comes a cropper in 64 bit after making a selection in a dropdown box, the database simply closes . This happens about 20 % of the time. nothing seems to be odd about the code within the after update in the dropdown box .

The code in the after update is populating a sub form with the contents of a table located in an external database that is not linked (this is done as the table chosen is very dynamic and linking via backend/front end is not viable.

It populates perfect in 32 bit and never crashes. If, in the 64 bit version of the database i open any other form, close it, then open the offending form it works perfectly every time, or if after i get the crash, reopen it it will work perfectly every time without having to open a different form first. the form is actually populating a sub form hence i tried to first populate the subform with a 'working form', then after a doevents command, populate the subform with the offending form. that doesnt help either



can anyone offer any advice as to why this might be happening, i would, sometime in the future have the database totally in 64bit but not at the moment with this happening on the only PC with 64 bit.
 

patrickS

New member
Local time
Today, 11:43
Joined
Nov 22, 2020
Messages
4
Further to the above, I also wonder if the populating of the sub form with data from this external database sometimes is causing the issue even though no error occurs, perhaps there is timing or file access over the network issue that sometimes occurs but is not generating a specific error that I can interroagate
 

arnelgp

error reading drive A:
Local time
Today, 10:13
Joined
May 7, 2009
Messages
12,403
post your API declaration.
putting PtrSafe is Not Enough to guarantee that the API will work on x64.
 

theDBguy

I’m here to help
Staff member
Local time
Yesterday, 19:13
Joined
Oct 29, 2018
Messages
14,958
Hi @patrickS. Welcome to AWF!

Also, please post the code for your dropdown.
 

The_Doc_Man

Immoderate Moderator
Staff member
Local time
Yesterday, 21:13
Joined
Feb 28, 2001
Messages
19,710
Is the external database Access or an active SQL engine like SQL server? That affects the connection method to some degree as well.
 

Users who are viewing this thread

Top Bottom