Results 1 to 2 of 2

Thread: Ado

  1. #1

    Thread Starter
    New Member
    Join Date
    May 2001
    Location
    MIDDLE EAST
    Posts
    6

    Exclamation Ado

    HI,
    I could use ADO datacontrol in my prgramme preveiously, but now i could use only dataenvironmet and ADODB by using code not ADO datacontrol the error message is 'object variable or with block variable not set'
    what will be the wrong

  2. #2
    PowerPoster Lethal's Avatar
    Join Date
    Oct 2000
    Location
    Ohio
    Posts
    2,496
    Your missing a Set statement. You must instantiate your object variables, not just declare them. For example:

    Code:
        RS as ADODB.Recordset
        CN as ADODB.Connection
    
    
        '// Instantiate objects
        Set RS = New ADODB.Recordset
        Set CN = New ADODB.Recordset

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width