webserv prog Connecting to an obdc database. Cannot perform this operation on a closed dataset

Posted on 2005-04-12
Last Modified: 2013-11-17
Im really stumped on this so if someone could help i would be very gratefull.

I have written a win-cgi webserv program which must manipulate databases.
the program was working but now when i run the program using "internet information services" on my machine i get the error
Exception: EDatabaseError
Message: UserTable: Cannot perform this operation on a closed dataset"

As far as i can tell my odbc settings are right becuase i am using a microsoft access database and it is registering the tables and fields in the c++builder5 ide.
i use this code to open the databse and it was working but i must have changed a something.

UserTable->Open(); this is the table.

Also if i set the connected property of the database to true the program does not load at all. instead it gives me the error
Exception: EDBEngineError
Message: An error occurred while attempting to initialize the Borland Database Engine (error $2B05)

From the borland website i found that...
$2B05 : permission denied

This is not an error in my code because i had a few programs connected to different database's but now they all give the same error when run.

Any help greatly appreciated.

Edit : i think now i am having this problem because i need to enter a username and password even though i have the login property set to false.
Does anyone know how i can turn off the need to log in each time the program runs?
Question by:Jim1981
    LVL 3

    Expert Comment

    haven't you changed the odbc/bde settings on your pc to require login?

    Author Comment

    Thanks for the reply.
    The thing is im not sure. Its my first time doing this stuff so i dont really know. If i double click on the database in the form it brings up an option screen where i can change the parameter overrides. Here there is a checkbox which says login prompt and i have this unchecked. is there anywhere else i have to change.
    Im really in trouble with this so any help at all is very welcome.
    LVL 3

    Accepted Solution

    It's a while since I have worked with BDE, but if i remember correctly you have to use the bde administrator to configure the setup (or odbc administrator if you are using an odbc driver).

    In ODBC Microsoft Access Setup there is an Advanced button that brings up a dialog where you set Default Authorization (login/password)

    For the bde access driver i think you only can give the user name, and have to supply the passord at runtime.


    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    Better Security Awareness With Threat Intelligence

    See how one of the leading financial services organizations uses Recorded Future as part of a holistic threat intelligence program to promote security awareness and proactively and efficiently identify threats.

    Update (December 2011): Since this article was published, the things have changed for good for Android native developers. The Sequoyah Project ( automates most of the tasks discussed in this article. You can even fin…
    Jaspersoft Studio is a plugin for Eclipse that lets you create reports from a datasource.  In this article, we'll go over creating a report from a default template and setting up a datasource that connects to your database.
    The viewer will learn how to use NetBeans IDE 8.0 for Windows to connect to a MySQL database. Open Services Panel: Create a new connection using New Connection Wizard: Create a test database called eetutorial: Create a new test tabel called ee…
    The viewer will learn how to use and create new code templates in NetBeans IDE 8.0 for Windows.

    779 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    9 Experts available now in Live!

    Get 1:1 Help Now