Ask Experts Questions for FREE Help !
Ask
    atristan's Avatar
    atristan Posts: 1, Reputation: 1
    New Member
     
    #1

    Mar 15, 2007, 05:21 AM
    The object doesn't contain the Automation object '|.'
    Hello,
    And thank you for taking this question. I currently support a small Access system and ran into the error mentioned in the title. I believe that the issue is system-specific because I ran the system from my desktop and printed fine. The issue centers around the cmdPrint command function. Here is the code that is running...

    Code:
    Private Sub cmdPrint_Click()
        Dim intCancel As Integer
    
        On Error GoTo Err_cmdPrint_Click
        
        Call Form_BeforeUpdate(intCancel)
        If Not intCancel Then
            DoCmd.RunCommand acCmdSaveRecord
            DoCmd.OpenReport "WSAR detail", acNormal, , "[WSAR Number]=" & WSAR_Number
        End If
    
    Exit_cmdPrint_Click:
        Exit Sub
    
    Err_cmdPrint_Click:
        MsgBox Err.Description
        Resume Exit_cmdPrint_Click
        
    End Sub
    When the user clicks print from his system, he gets the following error:
    The object doesn't contain the Automation object '|.'

    I found this information at Clearpoint Systems Code Library regarding this type of error but don't really understand what could be attempting to set a property or method:

    2766
    The object doesn’t contain the Automation object ‘|.’You tried to run a Visual Basic procedure to set a property or method for an object. However, the component doesn’t make the property or method available for Automation operations.@Check the component’s documentation for information on the properties and methods it makes available for Automation operations.
    Again, I believe that this issue is system-specific because I ran it fine and I have had no other complaints from any other users. Any leads would be greatly appreciated. Thank you have have a great day.
    ScottGem's Avatar
    ScottGem Posts: 64,966, Reputation: 6056
    Computer Expert and Renaissance Man
     
    #2

    Mar 15, 2007, 06:39 AM
    The problem may not be in this snippet of code. Unless WSAR Number is not a numeric datatype, the code looks correct. EVen if it wasn't you would get a different error.

    However this snippet also calls the Before Update event of the form. What you need to do is use Debug mode to find the EXACT line that is giving the error and post that. Then we may be able to spot the problem.

Not your question? Ask your question View similar questions

 

Question Tools Search this Question
Search this Question:

Advanced Search

Add your answer here.


Check out some similar questions!

Object in nose [ 8 Answers ]

:eek: Does anyone have any advice on getting an objecrt out of a child's nose? One of my son's stuck a bead in his nose and he is too young to blow, so it won't come out. It is not blocking his airway but I don't think it should stay in there. If nothing comes up I think I am taking him to the...

Strange object... [ 4 Answers ]

I'm a 17 year old male and I was recently diagnosed with Ulcerative Colitis. A feew weeks ago I noticed something near my anus... well actually right at the end of my tail bone. It's a round lump and its very hard. I can even move it around, like its just there under my skin attached to nothing....

Automation object [ 1 Answers ]

I wonder if you could help me? I started recentley working in a company. I am at the moment working on some listings of data bases in Access 2000. I was trying to make e customers phone list with the form similar to the one at Northwind Example. Everything went well with the table, form...


View more questions Search