469,592 Members | 1,889 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,592 developers. It's quick & easy.

string problem?

the following string was from windows 2000 server print eventlog message, i
want to get the print info. from the string, anybody can help me ?

1)Document 126, Exprot List 04-15.xls owned by jackzhang was printed on
printserver1 via port IP_192.168.0.1. Size in bytes: 46205; pages printed: 2

For more information, see Help and Support Center at
http://go.microsoft.com/fwlink/events.asp.

Nov 17 '05 #1
3 1071
Please supply more information as to what you are attempting.

If you are asking how to parse the string, you can use any of the static String.* functions for searching. A more robust solution
is to use System.Text.RegularExpressions.Regex for pattern matching (if the pattern of the eventlog info will always be the same).

The System.Diagnostics.EventLog class supplies you with a means for reading event log entries.

Hope that helps

--
Dave Sexton
dave@www..jwaonline..com
-----------------------------------------------------------------------
"roopeman" <ro******@discussions.microsoft.com> wrote in message news:9A**********************************@microsof t.com...
the following string was from windows 2000 server print eventlog message, i
want to get the print info. from the string, anybody can help me ?

1)Document 126, Exprot List 04-15.xls owned by jackzhang was printed on
printserver1 via port IP_192.168.0.1. Size in bytes: 46205; pages printed: 2

For more information, see Help and Support Center at
http://go.microsoft.com/fwlink/events.asp.

Nov 17 '05 #2
Hi,Dave, i just want get the print user,print date,printed pages,print
server,print computer IP Etc from the print eventlog message. pls.help me !

"Dave" wrote:
Please supply more information as to what you are attempting.

If you are asking how to parse the string, you can use any of the static String.* functions for searching. A more robust solution
is to use System.Text.RegularExpressions.Regex for pattern matching (if the pattern of the eventlog info will always be the same).

The System.Diagnostics.EventLog class supplies you with a means for reading event log entries.

Hope that helps

--
Dave Sexton
dave@www..jwaonline..com
-----------------------------------------------------------------------
"roopeman" <ro******@discussions.microsoft.com> wrote in message news:9A**********************************@microsof t.com...
the following string was from windows 2000 server print eventlog message, i
want to get the print info. from the string, anybody can help me ?

1)Document 126, Exprot List 04-15.xls owned by jackzhang was printed on
printserver1 via port IP_192.168.0.1. Size in bytes: 46205; pages printed: 2

For more information, see Help and Support Center at
http://go.microsoft.com/fwlink/events.asp.


Nov 17 '05 #3
Hi,

Then you will need to parse the string, a regex should be the best thing in
this escenario.

cheers,

--
Ignacio Machin,
ignacio.machin AT dot.state.fl.us
Florida Department Of Transportation

"roopeman" <ro******@discussions.microsoft.com> wrote in message
news:A4**********************************@microsof t.com...
Hi,Dave, i just want get the print user,print date,printed pages,print
server,print computer IP Etc from the print eventlog message. pls.help me
!

"Dave" wrote:
Please supply more information as to what you are attempting.

If you are asking how to parse the string, you can use any of the static
String.* functions for searching. A more robust solution
is to use System.Text.RegularExpressions.Regex for pattern matching (if
the pattern of the eventlog info will always be the same).

The System.Diagnostics.EventLog class supplies you with a means for
reading event log entries.

Hope that helps

--
Dave Sexton
dave@www..jwaonline..com
-----------------------------------------------------------------------
"roopeman" <ro******@discussions.microsoft.com> wrote in message
news:9A**********************************@microsof t.com...
> the following string was from windows 2000 server print eventlog
> message, i
> want to get the print info. from the string, anybody can help me ?
>
> 1)Document 126, Exprot List 04-15.xls owned by jackzhang was printed on
> printserver1 via port IP_192.168.0.1. Size in bytes: 46205; pages
> printed: 2
>
> For more information, see Help and Support Center at
> http://go.microsoft.com/fwlink/events.asp.
>


Nov 17 '05 #4

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

17 posts views Thread by Olivier Bellemare | last post: by
51 posts views Thread by Alan | last post: by
18 posts views Thread by Steve Litvack | last post: by
32 posts views Thread by tshad | last post: by
4 posts views Thread by MooMaster | last post: by
6 posts views Thread by tommaso.gastaldi | last post: by
4 posts views Thread by guiromero | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.