Access ADP

  • I have created an access ADP application. It all works fine for me and other users on XP machines. However using a Windows 2000 machine produces the following error for all users except myself.

    Run-time error 2757 There was a problem accessing the property or method of the OLE object. Clicking on the debug button takes you to the following line.

    docmd.openform.stdocname

    stdocname is the variable of the form name.

    If I log on to the windows 2000 machine it works

    I thought it must be some sort of permission problem and have checked and changed permissions on the SQL server with no luck

    To further complicate matters when logged on as the user I can open the tables and stored procedures and view all data.

    Any clues anybody

  • Your syntax is wrong.

    Use "docmd.openform stdocname" (with a space, not a dot), not docmd.openform.stdocname

    The error message is actually correct this time!

    The reason it behaves differently on your (development) machine could be one of several possibilites.  Since Access VBA is usually compiled only as needed, your development machine, with lots of changes and recompiles would be the first to find it.

    Make sure that you are only delivering compiled mde or ade apps to your users, and you should also regularly recompile your code to check for these types of syntax errors.

    Having said all that, erratic compilation errors are often a sign of a corrupted project.  You may want to consider importing all of your project objects into a new adp file.  It only takes a few minutes, and has eliminated really nasty problems for a lot of us.  (This is one of the undocumented tricks for getting rid of corrupted VBA code.)

  • Thanks

    my typing is wrong in this question and it does have a space in the code. I will try the other things you suggested.

  • Chris,

    just to throw another possibility into the ring, we see the "Run-time error 2757 There was a problem accessing the property or method of the OLE object." error with Access 2000 ADPs on Windows 2000 rather more frequently than we'd like to, and in our case it's always been a bogus error message where the real problem was a timeout.

  • I've also seen this error accur in many different situations. But most of the time for me it was a faulty SP as the data source of the form (sp was changed and raised an error because of a bug or a missing parameter or something else like that). You can try catching the event with the profiler and try it in QA to see if that's the problem.

  • What versions of MDAC are the XP and Win2000 clients running?

    Corie Curcillo
    MCT, MCDBA, MCSD

  • Thanks for everyones input. The problem was solved by logging onto a 2000 machine and changing the record source for the form property. On the 2000 machine it has DBO. in front of the stored procedure.

Viewing 7 posts - 1 through 6 (of 6 total)

You must be logged in to reply to this topic. Login to reply