Error In Loading DLL

Haytham

Registered User.
Local time
Today, 21:50
Joined
Jun 27, 2001
Messages
162
Hi All...
This is my code:
Private Sub Form_Open(Cancel As Integer)
With CodeContextObject
If (.RecordsetClone.RecordCount = 0) Then
DoCmd.close
Beep
MsgBox "You have No Records for the mentioned Period", vbOKOnly + vbInformation, "No Records"
End If
End With
End Sub

Whenever I try to open any form with no records, the mentioned cod works perfectly.
After Installing Windows xp , this code don't work anymore.
It's giving me Runtime error 48.
Any help please
 
I don't think you've to use CodeContextObject. This will also do:
Code:
Private Sub Form_Open(Cancel As Integer)
  If Me.RecordsetClone.Recordcount = 0 Then
    Beep
    MsgBox "You have No Records for the mentioned Period", vbOKOnly + vbInformation, "No Records"
    DoCmd.Close acForm, Me.Name
  End If
End Sub

But I'm not sure this solves the problem. Maybe there are one or more references missing (Tools, References)? It's possible that you had libraries on your previous windows-version, that aren't present at Windows XP by default. Maybe you've to link them again or to install them on you pc.
 
Hi SforSoftware,
The only last solution helped me is to import all of db into a new one, and then everything went well.
Thank you:rolleyes:
 

Users who are viewing this thread

Back
Top Bottom