How to have C# Web page query MSAccess Database and simultaneously populate MSAccess DB?

S

Siegfried Heintze

I have some cygwin cron jobs running under the Administrator account
populating a MSAccess database that is simultaneously being queried by
IIS/ASP.NET/C#.

If I manually use windows explorer to allow everyone to read/write/delete
the .mdl files created by the cygwin cron jobs, everything works. If I
don't, IIS/ASP.NET cannot open the MSAccess database.

How do I write a little web page to see what account I am running under? I
think I am running under the default of ISR_<machine name>. All I have to do
is make the cygwin cron job run under that account. What is the password for
ISR_<machine name>?

Thanks,
Siegfried
 
P

Paul Henderson

How do I write a little web page to see what account I am running under?

You just need to get the page to print out to the response the value of
System.Security.Principal.WindowsIdentity.GetCurrent().Name in your
Page_Load event [I think that nasty string of namespaces is right...].
I think I am running under the default of ISR_<machine name>. All I have to do
is make the cygwin cron job run under that account. What is the password for
ISR_<machine name>?

IIS will manage the password for this account, and will periodically
change it to a new random string. So, you can't really have a process
spawned manually run in the context of this account. Instead, you'd
probably have to set up a new account and have the ASP.NET pages run
under that account, rather than the default one, as then you'd also be
able to run your cron job in that account also.

HTH

-- ph
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,769
Messages
2,569,582
Members
45,057
Latest member
KetoBeezACVGummies

Latest Threads

Top