Click here to Skip to main content
15,913,941 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
hello I'm trying to create log source at the windows event viewer
I use this code just to open source :
System.Diagnostics.EventLog.CreateEventSource("LiorSprot.com", "LiorSprot");


and I get this the exception :
"Source was not found, but could not search some or all event logs. Logs not accessible: Security."

I run the asp applictaion in local host.

The problem is probably that I have no permission. But... how do I give permission? Maybe run administrator mode?

please help :)
Posted
Updated 8-Nov-14 13:58pm
v2

 
Share this answer
 
I explained the pattern of using custom Event Source in my past answer: How to create event log under a folder[^].

—SA
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900