An issue with macro conversion in Contacts database : Solved & Explained

johnbirt

Registered User.
Local time
Today, 01:25
Joined
Oct 31, 2009
Messages
20
Anyone that uses the Microsoft Access Contacts database template and converts the embedded macros to VBA will come across a few issues at least in Access 2010.

One particularly difficult one to trace (at least it took me ages to find it) is that the conversion produces the following event subroutine linked to a button.

Code:
Private Sub LabelWizard_MouseDown(Button as Integer,Shift as Integer, X as Double, Y as Double)
' Check for trusted project code here ....

End Sub
In fact this causes the VBA for the Contacts List form to compile incorrectly and the event subs following after this don't then work. For example a rather spurious error message referring to the event sub for txtOpen_Click being unrecognised occurs when that routine is perfectly OK.

The issue is caused by the two Double data types for X and Y which should actually be Single. Changing these removes the issue.

HTH.

There are a several other glitches which I will perhaps document in another post.

John B
 

Users who are viewing this thread

Back
Top Bottom