Hello Code Experts:
I inherited a recipe database from my aunt. The database was created by her husband who is no longer with us. RIP uncle.
I loaded the Microsoft Access database on my laptop but when I go into view a recipe I receive the following error message.
Error Code Form:
Compile Error:
The code in this project must be updated for use on 64-bit systems. Please review and update Declare statements and then mark them with the PtrSafe attribute.
Can someone help update the code from a 32-bit to a 64-bit so that I can use the database on my laptop please. Your time is appreciated.
I have the following system:
Windows: Windows 7
System Type: 64-bit Operating System
Intel(R) Core(TM) i5-4300M CPU @ 2.6GHz
The following is the VB code where it errors:
<Begin Code>
Option Compare Database
Option Explicit
Private Declare Function GetClassNameA Lib "user32" ( _
ByVal hwnd As Long, _
ByVal lpClassName As String, _
ByVal nMaxCount As Long) _
As Long
Private Declare Function GetWindow Lib "user32" ( _
ByVal hwnd As Long, _
ByVal wCmd As Long) _
As Long
Private Declare Function ShowWindowAsync Lib "user32" ( _
ByVal hwnd As Long, _
ByVal nCmdShow As Long) _
As Boolean
Private Const GW_HWNDNEXT = 2
Private Const GW_CHILD = 5
Private Const SW_HIDE = 0
Private Const SW_SHOW = 5
<End Code>
I inherited a recipe database from my aunt. The database was created by her husband who is no longer with us. RIP uncle.
I loaded the Microsoft Access database on my laptop but when I go into view a recipe I receive the following error message.
Error Code Form:
Compile Error:
The code in this project must be updated for use on 64-bit systems. Please review and update Declare statements and then mark them with the PtrSafe attribute.
Can someone help update the code from a 32-bit to a 64-bit so that I can use the database on my laptop please. Your time is appreciated.

I have the following system:
Windows: Windows 7
System Type: 64-bit Operating System
Intel(R) Core(TM) i5-4300M CPU @ 2.6GHz
The following is the VB code where it errors:
<Begin Code>
Option Compare Database
Option Explicit
Private Declare Function GetClassNameA Lib "user32" ( _
ByVal hwnd As Long, _
ByVal lpClassName As String, _
ByVal nMaxCount As Long) _
As Long
Private Declare Function GetWindow Lib "user32" ( _
ByVal hwnd As Long, _
ByVal wCmd As Long) _
As Long
Private Declare Function ShowWindowAsync Lib "user32" ( _
ByVal hwnd As Long, _
ByVal nCmdShow As Long) _
As Boolean
Private Const GW_HWNDNEXT = 2
Private Const GW_CHILD = 5
Private Const SW_HIDE = 0
Private Const SW_SHOW = 5
<End Code>