Re: My Service needs to acces the Registry...
From: Alexander Bauer (Alexander.Bauer_at_AlBaWare.de)
Date: 10/16/03
- Next message: Fauschti: "Re: application.hide .."
- Previous message: GenJerDan: "Re: Setting IP Address (Registry)"
- In reply to: Serguei: "Re: My Service needs to acces the Registry..."
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Thu, 16 Oct 2003 21:23:56 +0200
Wow, that was quite fast and verry usefull too - many thanks.
I think I can make it work with this inforamtion.
Thanks again and
Kind regards,
Alexander Bauer
"Serguei" <nospam@nowhere.no> schrieb im Newsbeitrag
news:3f8ed744$1@newsgroups.borland.com...
>
> Hello,
> By default your service runs under "local system" account,
> which has low permissions.
> You may configure it to run under different account:
> see control panel->Adminiostrative Tools->Services->
> Properties->Log On.
>
> If it is not an option, your service may impersonate as
> different user just for the time when accessing the registry.
>
> >Also I've seen that I have to define some event-id texts
> > for the loggin in the Win2K eventlog.
> There are two parts for writing events:
> 1) You will have to define the message table resource,
> and register it as an event source. You may still
> write the events into the log without this step,
> but the message text
> containg your text along with the warning:
>
> "The description for Event ID ( 0 ) in Source ( Application ) cannot be
found. The local computer may not have the necessary registry information or
message DLL files to display messages from a remote computer. The following
information is part of the event:" YOUR TEXT HERE.
>
> 2) Call ReportEvent api function.
> See also TNTEventLog component:
> http://www.online-admin.com/ntset.html#TNTEventLog
>
> Hope this helps,
> Serguei
>
> "Alexander Bauer" <Alexander.Bauer@AlBaWare.de> wrote:
> >Hi all,
> >
> >It's my verry first Service I'm trying to write and I have some problems.
> >
> >The sevice should scan a MS Access DB for some special field values via
ADO.
> >This is tested in an app and working fine so far.
> >
> >The problem is:
> >I first get the name of the System-DSN out of an INI-File (works fine).
> >Now I try to read data from this System-DSN from the Registry.
> >Anything is OK but the service seems not to be allowed to access the
> >registry - My test-app can read anything fine, so I think it's nothing
wrong
> >with me reg-access stuff (it's omply copied to the service). Can any one
> >tell me what I'd miss?
> >
> >Also I've seen that I have to define some event-id texts for the loggin
in
> >the Win2K eventlog.
> >How / where to do that?
> >
> >Thanks in advance.
> >
> >Regards,
> > Alexander Bauer
> >
> >
>
- Next message: Fauschti: "Re: application.hide .."
- Previous message: GenJerDan: "Re: Setting IP Address (Registry)"
- In reply to: Serguei: "Re: My Service needs to acces the Registry..."
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]