473,765 Members | 2,047 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

How to specify the EventLog file location?

RA
Hi

Is there a way to specify where the custom EventLog file will be created?
Thanks
Nov 15 '05 #1
1 1779
On Tue, 13 Jan 2004 11:05:27 -0600, "RA" <ro****@hotmail .com> wrote:
Hi

Is there a way to specify where the custom EventLog file will be created?
Thanks


Are you asking whether it's possible to specify whether you can save
under "Applicatio n", "Security" or "System"? Or do you mean something
else?

To specify (for example) "Applicatio n", do something like:

just use the def. constructor:
EventLog mylog = new EventLog();

followed by:
mylog .Log = "Applicatio n";

Alternatively use one of the constructors that take "LogName" as an
argument.
If you're asking whether you can save the actual logfile (controlled
by Eventviewer, I believe) to some other place, then I don't know.
Nov 15 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
25040
by: Till Soerensen | last post by:
I would like to validate a xml file against a xsd file on my hard disc. Ok, I could specify the location of the XSD Schema in the instance of the xml file as follows: <Person xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="file:///D:/tmp/Personschema.xsd"> It works. But I would like to specify the location of the xsd relative to the xml file. That means if I move both xml AND xsd schema to another...
5
2337
by: timb | last post by:
Hi, am creating a windows service using c# and would like it to create a new eventlog logtype and add it to the eventlog viewer so that i can log all messages relating to this application to this specific log. Does anyone have any code for this which works as i have tried the examples but am unable to find the log in the eventlogviewer or anywhere on the hard drive afterwards. Thanks in advance TimB
1
7289
by: john s | last post by:
I am trying to create a message text file for the Catagory field in order to map the catagory input number to a string text. I have found some MSDN information on this, but it appears to only be for C/C++. What I have found in MSDN so far can be found here: http://msdn.microsoft.com/library/default.asp?url=/library/en-us/debug/base/message_files.asp and...
0
1161
by: sangui | last post by:
..Net provide the class to read eventlog (EventLog class) but I try to read the window eventlog per file. without using EventLog Class. is it possible to read the log per file? public static void Main() { EventLog remoteEventLogs;
3
15635
by: John Lee | last post by:
Hi, we have been trying so many days and could not figure it out - please help!!! in windows 2003, we created an application pool and assigned a domain account as its identity - we also assigned this domain account to IIS_WPG group, and also assigned this domain account all priviledges that NETWORK SERVICE has in local security policy mmc ... but when we try to use System.Diagnosis.EventLog.WriteEntry("source", "test") we got access...
3
4839
by: Ben | last post by:
I am trying to write an eventlog monitor. I am using the sample code provided by VB2005 SDK as the bases for my application. I need to monitor all three logs (application, system, and security). How can I monitor all three logs at once? Thanks,
0
1818
by: rene | last post by:
I'm trying to use costome categories in my eventlog for a program I'm writing. But I have some problems with it, I cant get it to work. Checklist for how I did this. 1. Created a resourceful.mc content is like this. MessageId=0x1 Severity=Success SymbolicName=INSTALL_CATEGORY
1
1872
by: Max2006 | last post by:
Hi, We are using EventLogWebEventProvider. All events within the event log viewer appear as : Type=Warning Source= ASP.NET 2.0.50727.0 Category= Web Event Is there any way to customize above settings in web.config?
1
2046
by: Jeff | last post by:
hi ..Net 2.0 I've created the code below and think I've executed it. After I thought I've executed it I checked in EventLog on the computer (win2k3) and no entry was added. This could mean 2 things: - There are some logical errors in my code - The code wasn't actually executed
0
9568
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
10164
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10007
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
7379
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6649
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5423
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
3926
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3532
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2806
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.