Thank Bon it works but I have to give it full permission and opendatabase in
exclusive mode.
The issue again here after I load it from ASP page I can't open the MDB file
until I end process aspnet_wb.exe
I am not sure how to configure the impersonate identity.
"Bonj" <Bo**@discussions.microsoft.com> wrote in message
news:8B**********************************@microsof t.com...
no it won't , you do need DAO for that. Still can't get it to work with
those suggestions?
"kids_pro" wrote:
I need DAO because I want to create/update Query in MDB file on fly.
I don't think ADO.NET allow me to do that.
"Bonj" <Bo**@discussions.microsoft.com> wrote in message
news:A8**********************************@microsof t.com... Presumably you've made sure the database is in the c:\ drive of the
server.. a) set the ASPNET account to have the correct permissions?
b) set the 'impersonate identity' property to true in the web.config ?
Does File.Exists work on it, or does ADO.NET work on it?
(ADO.NET is largely better than DAO for most things...what do you use
DAO for?)
"kids_pro" wrote:
> Hi there,
>
> I am using DAO to read data from MDB file I try the following
command to > open database.
> DBEngine dbEng = new DBEngineClass();
> Workspace ws = dbEng.Workspaces[0];
> db = ws.OpenDatabase(filename, true,false, ";UID=Admin;PWD=" +
> Password_DbAdmin);
>
> It is work fine with Window Application. But when I try to call it
from > ASP.NET webform I got the following error:
> The Microsoft Jet database engine cannot open the file
'C:\Nation.mdb'. It > is already opened exclusively by another user, or you need
permission to > view its data.
>
> I did try to set full permission on the file for IUSR_COMPUTER_NAME
but it > still give that error.
>
> Please help.
>
>
>