473,506 Members | 11,491 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

"Safe" event source to write to

Is there a safe Application log event source? By safe, I mean one that will
always exist (excluding any manual deletion) on any and all normal xp, 2003
installations. I thought "Application" was one but apparently its not.

Kevin
Nov 16 '05 #1
3 1299
You don't have an Application log? Perhaps it is just a permissions
issue.

--
Scott
http://www.OdeToCode.com/blogs/scott/

On Mon, 13 Dec 2004 08:11:40 -0600, "Kevin C" <kc@noneya.com> wrote:
Is there a safe Application log event source? By safe, I mean one that will
always exist (excluding any manual deletion) on any and all normal xp, 2003
installations. I thought "Application" was one but apparently its not.

Kevin


Nov 16 '05 #2
Kevin,

There is no reason you can not make it safe. Why not write a method
which takes the name of the log, and the event to write, and check to see if
it exists before trying to write it? If it doesn't exist, do nothing,
otherwise, write it.

Hope this helps.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Kevin C" <kc@noneya.com> wrote in message
news:eF*************@TK2MSFTNGP12.phx.gbl...
Is there a safe Application log event source? By safe, I mean one that
will
always exist (excluding any manual deletion) on any and all normal xp,
2003
installations. I thought "Application" was one but apparently its not.

Kevin

Nov 16 '05 #3
I think I worded this wrong. What I am looking for is a string value ; e.g.
"Application Exception", that represents a pre-installed event source on a
normal XP, 2003 installation. In other words, if the permission trying to
create my custom event source fails, I want to fallback and use an event
source that I am 99% am guaranteed is on the machine. Therefore, I can log
the fact that the permission failed but still get my message into the event
log. Does this make more sense?

Kevin
"Nicholas Paldino [.NET/C# MVP]" <mv*@spam.guard.caspershouse.com> wrote in
message news:O%****************@TK2MSFTNGP12.phx.gbl...
Kevin,

There is no reason you can not make it safe. Why not write a method
which takes the name of the log, and the event to write, and check to see if it exists before trying to write it? If it doesn't exist, do nothing,
otherwise, write it.

Hope this helps.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Kevin C" <kc@noneya.com> wrote in message
news:eF*************@TK2MSFTNGP12.phx.gbl...
Is there a safe Application log event source? By safe, I mean one that
will
always exist (excluding any manual deletion) on any and all normal xp,
2003
installations. I thought "Application" was one but apparently its not.

Kevin


Nov 16 '05 #4

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

Similar topics

4
11658
by: /dev/null | last post by:
Is there a function in php that you can pass a string headed for a mysql query and have it make it 'safe'? For example it would escape out the ' found in the string. Thanks!
8
2236
by: Doug Laidlaw | last post by:
I tried to grab an image from a Web page the other day. It turned out that the page was made up of three horizontal bands, and part of the image was in each. One band was a JPEG, another was a...
1
1935
by: Jeff Yang | last post by:
These days,I have read the artile "Safe, Simple Multithreading in Windows Forms, Part 1" on MSDN,and I also runed the example of it....
4
4448
by: lwickland | last post by:
Non-visual C# objects on a webpage are not marked as "safe for scripting" I'm developing .NET components in C# which are used as ActiveX-style controls on web pages that are displayed inside a...
2
6470
by: SharpCoderMP | last post by:
hi, i'm writing a console application and i would like to be able to safely retrive password from the user, so noone can see how it is being typed. consider this scenario: Console.Write("Enter...
1
6441
by: laredotornado | last post by:
Hi, I'm using PHP 4.4.4 on Apache 2 on Fedora Core 5. PHP was installed using Apache's apxs and the php library was installed to /usr/local/php. However, when I set my "error_reporting"...
2
5144
by: semedao | last post by:
Hi , someone know the reason and how to handle it? thanks
6
9250
by: kellygreer1 | last post by:
What is a good one line method for doing a "length safe" String.Substring? The VB classes offer up the old Left function so that string s = Microsoft.VisualBasic.Left("kelly",200) // s will =...
0
1002
by: martin.nordstrom87 | last post by:
I'm making a game where you'll be able to make your own mods and I want to be able to write these mods in python. However, python has a lot of "dangerous" functions (like erase any file on the...
0
7220
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,...
0
7308
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,...
0
7479
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
5617
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
1
5037
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...
0
4702
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...
0
3178
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
1534
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 ...
0
410
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...

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.