PC Review Forums Newsgroups Microsoft Access Microsoft Access VBA Modules VB CODE ERROR

Reply

VB CODE ERROR

 
Thread Tools Rate Thread
Old 31-01-2004, 04:24 PM   #1
SAM
Guest
 
Posts: n/a
Default VB CODE ERROR



I am trying to run the code below and I get this error
message. This code has been working fine in access XP but
when I attempt to use it in access 2000 I get this error
Can someone HELP!

Automation Error
Incorrect Inheritance depth in standard OLE hmember


Private Sub Form_Current()

If Not IsDate(Me.Notice_Return) Then
If DateDiff("d", Me.Notice_Sent, Date) >= 315 Then
MsgBox "You Have Georgia Comp. Hours You Are About
To Lose YOU HAVE 60 DAYS TO TAKE THESE HOURS", vbOKOnly +
vbExclamation
End If
End If

  Reply With Quote
Old 02-02-2004, 03:29 AM   #2
Dirk Goldgar
Guest
 
Posts: n/a
Default Re: VB CODE ERROR

"SAM" <anonymous@discussions.microsoft.com> wrote in message
news:7bf601c3e80e$5ff95db0$a501280a@phx.gbl
> I am trying to run the code below and I get this error
> message. This code has been working fine in access XP but
> when I attempt to use it in access 2000 I get this error
> Can someone HELP!
>
> Automation Error
> Incorrect Inheritance depth in standard OLE hmember
>
>
> Private Sub Form_Current()
>
> If Not IsDate(Me.Notice_Return) Then
> If DateDiff("d", Me.Notice_Sent, Date) >= 315 Then
> MsgBox "You Have Georgia Comp. Hours You Are About
> To Lose YOU HAVE 60 DAYS TO TAKE THESE HOURS", vbOKOnly +
> vbExclamation
> End If
> End If


There's nothing in that code itself that could cause such an error. I
don't know what "Notice_Return" or "Notice_Sent" are, but if they're
simple text boxes I doubt they could be the cause of the problem. Have
you stepped line by line through the code to see on exactly which line
the error is being raised?

Have you just copied a working database from an AXP system to an A2K
system? Maybe there's a problem with the references. See if the
procedures outlined in the following article help:


http://members.rogers.com/douglas.j...enceErrors.html

--
Dirk Goldgar, MS Access MVP
www.datagnostics.com

(please reply to the newsgroup)


  Reply With Quote
Reply



Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off