Home All Groups Group Topic Archive Search About

How to get current cpu usage as well as memory and others?

Author
14 Dec 2006 7:14 PM
Andrew
I am using vb.net VS 2005.

can anybody point me in the direction of getting:

current cpu usage %, total proccess running at a snapshot, number of
processors.

Total memory in machine, and memory used,

total drives, drive copacity and used space.

I am trying to take snapshots of the system a few times a day and add them
to a database for processing pc server health.

I can not find any good examples in vb 2005.

can anybody help?

does anybody know how to get the windows SDK? , will that help?

Author
15 Dec 2006 1:57 AM
Newbie Coder
Use WMI


Show quoteHide quote
"Andrew" <And***@discussions.microsoft.com> wrote in message
news:5A36DC03-BDEF-4B82-9813-707194496E02@microsoft.com...
> I am using vb.net VS 2005.
>
> can anybody point me in the direction of getting:
>
> current cpu usage %, total proccess running at a snapshot, number of
> processors.
>
> Total memory in machine, and memory used,
>
> total drives, drive copacity and used space.
>
> I am trying to take snapshots of the system a few times a day and add them
> to a database for processing pc server health.
>
> I can not find any good examples in vb 2005.
>
> can anybody help?
>
> does anybody know how to get the windows SDK? , will that help?
Author
15 Dec 2006 9:52 AM
Jens
system.environment.* should contain some of the things you're searching for,
e.g. the cpu count.

There is another class outside system that makes it very easy to read
free/used/total memory. But I don't remember it right now.
Author
15 Dec 2006 11:47 PM
Nip
System.Diagnostics should do the job aswell

Show quoteHide quote
"Jens" <J***@discussions.microsoft.com> wrote in message
news:8F6FA5D1-1513-4CDA-AEBF-752F2DE08095@microsoft.com...
> system.environment.* should contain some of the things you're searching
> for,
> e.g. the cpu count.
>
> There is another class outside system that makes it very easy to read
> free/used/total memory. But I don't remember it right now.