By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
440,333 Members | 1,850 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 440,333 IT Pros & Developers. It's quick & easy.

creating application........

P: 8
hi users,
i m new to this site, so kindly plz help me in my query. i m creating a windows based application in .net c# which can monitor all the user details like opening/closing of application,user login/logout,system start/shutdown and screensaver monitoring details.plz help me out as i m trying to fing the root directory from where i can get the track of all running applications.also i dont wanna use the timer control in the above application so what can be the possible alternatives for the above mentioned query.looking forward for all ur responses in a quick time...........
Oct 29 '07 #1
Share this Question
Share on Google+
10 Replies


radcaesar
Expert 100+
P: 759
Refer to the library

System.Diagnostics (or) WMI also preferable to do this.

:)
Oct 29 '07 #2

P: 5
hi users,
i m new to this site, so kindly plz help me in my query. i m creating a windows based application in .net c# which can monitor all the user details like opening/closing of application,user login/logout,system start/shutdown and screensaver monitoring details.plz help me out as i m trying to fing the root directory from where i can get the track of all running applications.also i dont wanna use the timer control in the above application so what can be the possible alternatives for the above mentioned query.looking forward for all ur responses in a quick time...........
use this code in your application . i hope ur problem will be solved

Using System.Diagnostics;
foreach ( Process p in Process.GetProcesses(System.Environment.MachineNam e) )
{
if( p.MainWindowHandle != IntPtr.Zero)
{
Console.WriteLine( p ); // string s = p.ToString();
}
}
Oct 29 '07 #3

P: 8
use this code in your application . i hope ur problem will be solved

Using System.Diagnostics;
foreach ( Process p in Process.GetProcesses(System.Environment.MachineNam e) )
{
if( p.MainWindowHandle != IntPtr.Zero)
{
Console.WriteLine( p ); // string s = p.ToString();
}
}
hi users,
thanks for ur post and interest but the above solution is not solving the purpose. i have to track the time of opening and closing the application i.e monitoring of windows application,system login/logoff and system start/shutdown
Oct 30 '07 #4

P: 8
i think importing some dll might solve my problem.suggest me on that
Oct 30 '07 #5

P: 8
reply needed urgently.plz reply fast.thankyou for your support
Oct 30 '07 #6

Shashi Sadasivan
Expert 100+
P: 1,435
run a timer with the min accuracy you need, and keep kicking off the process code as suggested by pankajinfoedge
even the process viewer does the same thing. a dll will only be inplementing a timer based function (even if it existed...there are no shortcuts)
Oct 30 '07 #7

P: 8
hi all,
i am creating an application which monitors screensaver start and stop activity,also lock/unlock of a computer.i need some assistance on dat.plz help me on dis
Nov 5 '07 #8

P: 8
hi all,
i discussed my query to all of you couple of days back. i think none of you all looked into it. plz read my prob. and help me out as much as you can. looking for your replies as soon as possibl.......
mohit
Nov 7 '07 #9

10K+
P: 13,264
hi all,
i discussed my query to all of you couple of days back. i think none of you all looked into it. plz read my prob. and help me out as much as you can. looking for your replies as soon as possibl.......
mohit
Refer to post #2 in this thread.
Nov 7 '07 #10

balabaster
Expert 100+
P: 797
Refer to post #2 in this thread.
Well in order to monitor user logins to the system, it will have to be a windows service so that it can run in a shell context...probably with an automatic startup so that it starts prior to any users logging on...so you're going to need to take that into account. You'll then monitor the process list and when a process is instantiated a record of the time it was started and the user that started it up. WMI should work for this. It seems relatively straight forward. The screen saver starts an executable so you can catch this too...of course, I'm not sure how you can tell who stopped the screen-saver. Because even if it's passworded any administrator could stop it...of course that would cause the old user to be logged off. I'm still not sure how you would tell who'd logged that person off...
Nov 7 '07 #11

Post your reply

Sign in to post your reply or Sign up for a free account.