[AccessD] DECLARE and SafePtr
Jim Dettman
jimdettman at verizon.net
Sat Oct 23 07:52:36 CDT 2021
Arthur,
You should give this page a read:
https://codekabinett.com/rdumps.php?Lang=2&targetDoc=windows-api-declaration
-vba-64-bit
as it explains about the compiler constants and when you might use them,
along with LongLong, LongPrt, and PtrSafe
and besides the file that Borge mentioned, there is a good reference here:
https://jkp-ads.com/articles/apideclarations.asp
with the correct syntax.
Jim.
-----Original Message-----
From: AccessD On Behalf Of Borge Hansen
Sent: Saturday, October 23, 2021 1:12 AM
To: Access Developers discussion and problem solving
<accessd at databaseadvisors.com>
Subject: Re: [AccessD] DECLARE and SafePtr
Hi Arthur,
I've been following your thread re upgrading your Access app from 32bit to
64bit.
I went through the exercise earlier this year.
I recommend that you have both a 32bit and 64bit version of your Office
running (on two different machines or VMs of course) to test that the app
will run both on 32bit version of Office and 64bit version. Your client may
have a mix of 32bit and 64bit Office.
If you have any third party DLLs - or similar - that your app is dependent
on, make sure that a 64bit version is available.
I used this file:
Win32API_PtrSafe.TXT
to help me with the conversion.
I would search in our vba code for all instances of
Lib "Kernel32"
and then copy and paste and search for the specific Declare Function in the
TXT file, (I would use Sublime Text for searching the .TXT file).
Then copy and paste the whole Declare PtrSafe Function over the existing
Declare ... Lib "Kernel32" function.
In only a few instances did I need to include testing - doing a
#If Win64 then
- and include the two different Lib "Kernel32" functions...
You can download the
Win32API_PtrSafe.TXT
from here:
https://docs.microsoft.com/en-us/office/troubleshoot/office-suite-issues/win
32api_ptrsafe-with-64-bit-support
Hope this helps...
/borge
On Sat, Oct 23, 2021 at 12:12 PM Arthur Fuller <fuller.artful at gmail.com>
wrote:
> What s the syntax for such a Declare statement/
>
> --
> Arthur
> --
> AccessD mailing list
> AccessD at databaseadvisors.com
> https://databaseadvisors.com/mailman/listinfo/accessd
> Website: http://www.databaseadvisors.com
>
--
AccessD mailing list
AccessD at databaseadvisors.com
https://databaseadvisors.com/mailman/listinfo/accessd
Website: http://www.databaseadvisors.com
More information about the AccessD
mailing list