Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
MmApplicationLog.WriteTrace
Message
 
À
23/06/2004 11:07:21
Information générale
Forum:
ASP.NET
Catégorie:
The Mere Mortals .NET Framework
Divers
Thread ID:
00914638
Message ID:
00916672
Vues:
8
>In stepping thru the code, it looks as if
>
>a) All errors are ignored. I can understand a recursive spiral caused by the
>error handler being invoked within the error handler, but would think that a failed log write should at least show up in the debug console window?
>
>and
>
>b) I get {"Requested registry access is not allowed." } from the writeInfo call.
>
>So I'm not sure how to proceed. Is there a way to configure a webapp to talk with the server application log?

There is...it's a bit different than a Windows Forms application because of the limited rights of the ASPNET account. Here's an excerpt from a Microsoft white paper on the subject:

"Applications that need to write to the Application event log can do so while running as the ASPNET account. If an application needs to create a new event log category, it must create a registry key under the HKLM hive, which the ASPNET account cannot do. If impersonation is enabled and a privileged account is impersonated, the category can be created at run time. Otherwise, an administrator can create the category and the application can write to it at run time.

Applications that need to create new event log categories should create the categories at installation. Once the category is created, the ASPNET account can write to the log."

Here is a link to the full whitepaper:

http://www.gotdotnet.com/team/upgrade/v1/aspnet_account_readme.doc

Regards,
Kevin McNeish
Eight-Time .NET MVP
VFP and iOS Author, Speaker & Trainer
Oak Leaf Enterprises, Inc.
Chief Architect, MM Framework
http://www.oakleafsd.com
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform