Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > ActiveX COM > Report Control
  New Posts New Posts RSS Feed - Error 3420
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Error 3420

 Post Reply Post Reply
Author
Message
cryo75 View Drop Down
Groupie
Groupie


Joined: 04 June 2006
Status: Offline
Points: 49
Post Options Post Options   Thanks (0) Thanks(0)   Quote cryo75 Quote  Post ReplyReply Direct Link To This Post Topic: Error 3420
    Posted: 08 December 2006 at 12:38pm
Hi,
 
I'm getting an error 3420 (The object is not valid anymore) with the following code:
 
        With grdList
            For Each oRec In grdList.Records
                eType = Val(oRec.Item(ID_GRID_TYPE).Value)
                If (eIngType = bbMyType)  Then
                    oRec.Visible = True
                Else
                    oRec.Visible = False
                End If
            Next oRec
   
            .Populate
        End With
 
The line causing the error is:
eType = Val(oRec.Item(ID_GRID_TYPE).Value)
The item object is totally empty (it looks like an ADO field object). I have previously filled all records (and items) by loop through my own ado recordset and setting values.
 
Any ideas?
 
Thanks,
Ivan
Back to Top
cryo75 View Drop Down
Groupie
Groupie


Joined: 04 June 2006
Status: Offline
Points: 49
Post Options Post Options   Thanks (0) Thanks(0)   Quote cryo75 Quote  Post ReplyReply Direct Link To This Post Posted: 09 December 2006 at 2:18am
Problem solved!
 
The Additem method of the record object accepts a variant. I was adding the ado field object. I needed to pass the field's value!!
 
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.04
Copyright ©2001-2021 Web Wiz Ltd.

This page was generated in 0.199 seconds.