473,322 Members | 1,714 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,322 software developers and data experts.

How can I read the property's "Description" of a security Log's en

I'm using vs2005, .net 2.0 on Windows 2000 server.
When I double click on an entry of the "Security" log in the system's "Event
Viewer", a Property window pops up. In this window, there is a "Description"
section that lists many different information like "User Name:, "Domain",
"Login ID"......
How can I obtain each of this inforation in my program? Thank you.

--
Thanks.
Dec 3 '06 #1
1 1456
Pucca wrote:
I'm using vs2005, .net 2.0 on Windows 2000 server.
When I double click on an entry of the "Security" log in the system's "Event
Viewer", a Property window pops up. In this window, there is a "Description"
section that lists many different information like "User Name:, "Domain",
"Login ID"......
How can I obtain each of this inforation in my program? Thank you.
Try using the EventLog and EventLogEntry classes in System.Diagnostics:

EventLog eventLog = new EventLog("Security");
foreach (EventLogEntry entry in eventLog.Entries)
{
Console.Out.WriteLine(entry.Message);
}
Dec 3 '06 #2

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

Similar topics

2
by: Pablo | last post by:
Friends! I need to show the dialog "select folder" and get the path selected, using vb.net. The OpenFileDialog control is useless as I want to select a folder and not a file. In vb6 I achieved...
0
by: John Phelan-Cummings | last post by:
What Works I have a subform (Events1) with a combo box field called “eventname”. The combo box displays the correct information from the second column of its lookup table, i.e., column #1:...
11
by: MLH | last post by:
I have a query field... Description: & "2-tone" When I run it, the output in that field is empty. If I change the name to MyDescription - it works fine. I noticed the query field has a...
4
by: marclinenberger | last post by:
If you right click on a table name in the tables window and click on properties you get a dialog box that allows you to add a description of the table. My question is using VBA how do you access...
0
by: bbcrock | last post by:
I have approximately 400 column descriptions stored in an MS Word document in MS Word tables that I want to insert into SQL Server utilizing the sys.sp_addextendedproperty function. Cutting and...
4
by: thaytu888888 | last post by:
Here is my codes in aspx page: <td colspan="2" class="main_menu" runat="server" onclick='toggleDisplay(<%#Eval("description")%>);'><%#Eval("description")%></td> Here is in "View source": ...
2
by: atishrg | last post by:
Hello All Need your help.. I created addin for outlook 2007 in vs2005(vb.net)... It is working fine now I Migrated that to vs2008 and created setup for that in vs2008...
8
by: ismailc | last post by:
Hi, I would like to change the text color of (<xsl:value-of select="Description") onmouseover of image. the javascript works, it's just that i can seem to get the name correct <td>...
1
by: silverachilles | last post by:
Hello, I have php code which takes an rss feed and outputs it on a page of my website. For each item it shows the link, title and description. My problem is the description element contains a lot...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 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 former...

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.