473,413 Members | 2,053 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,413 software developers and data experts.

Getting the current system

Hi,

I developed an application on my workstation which is a P4 2.4G. Now that
my application is almost finished, I find out that this app will be used on
the road by technicians using laptops(gota love inter-office communication).
This causes a *major* problem because my app is very UI intensive (its got
many graphs displayed in real-time) and tests on our own laptops show that
they just cant cut it. (I'm not saying anything againts laptops, beeing a
big fan myself, its just that their graphics adapters aren't as powerfull).

Anyway, I'm going to include two configurations of my program. A full
version for powerfull pcs, and another smaller, less intensive version for
older pcs/laptops.

My question is, is it possible for my app to know if its running on a
laptop, or a PentiumII? Is there a way for me to know what CPU is running
and at what speeds?

Thanks and best regards,

Marco
Nov 15 '05 #1
4 1172
Marco,

You can definitely get this. You can get almost any system information
you want using the classes in the System.Management namespace. Basically,
you can query for WMI classes (which are not .NET classes) which have the
values that you want. You can get information about the processor, the
graphics card, etc, etc.

You probably want to look for instances of the Win32_Processor class and
the Win32_VideoController class.

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

"Marco Martin" <ma**********@sympatico.ca.antispam> wrote in message
news:%x********************@news20.bellglobal.com. ..
Hi,

I developed an application on my workstation which is a P4 2.4G. Now that
my application is almost finished, I find out that this app will be used on the road by technicians using laptops(gota love inter-office communication). This causes a *major* problem because my app is very UI intensive (its got
many graphs displayed in real-time) and tests on our own laptops show that
they just cant cut it. (I'm not saying anything againts laptops, beeing a
big fan myself, its just that their graphics adapters aren't as powerfull).
Anyway, I'm going to include two configurations of my program. A full
version for powerfull pcs, and another smaller, less intensive version for
older pcs/laptops.

My question is, is it possible for my app to know if its running on a
laptop, or a PentiumII? Is there a way for me to know what CPU is running
and at what speeds?

Thanks and best regards,

Marco

Nov 15 '05 #2
Thanks Nicholas,

Thats exacly what I needed. Now I just have to figure out how I'm going to
use this information.

I'm trying to do something like;

if(bolCrappyCPU || bolCrappyVideoCard)
{
//do something
}
else
{
//do something else
}

regards,

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

You can definitely get this. You can get almost any system information you want using the classes in the System.Management namespace. Basically,
you can query for WMI classes (which are not .NET classes) which have the
values that you want. You can get information about the processor, the
graphics card, etc, etc.

You probably want to look for instances of the Win32_Processor class and the Win32_VideoController class.

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

"Marco Martin" <ma**********@sympatico.ca.antispam> wrote in message
news:%x********************@news20.bellglobal.com. ..
Hi,

I developed an application on my workstation which is a P4 2.4G. Now that my application is almost finished, I find out that this app will be used

on
the road by technicians using laptops(gota love inter-office

communication).
This causes a *major* problem because my app is very UI intensive (its got many graphs displayed in real-time) and tests on our own laptops show that they just cant cut it. (I'm not saying anything againts laptops, beeing a big fan myself, its just that their graphics adapters aren't as

powerfull).

Anyway, I'm going to include two configurations of my program. A full
version for powerfull pcs, and another smaller, less intensive version for older pcs/laptops.

My question is, is it possible for my app to know if its running on a
laptop, or a PentiumII? Is there a way for me to know what CPU is running and at what speeds?

Thanks and best regards,

Marco


Nov 15 '05 #3
Marco,

Since you said the graphs are the culprit, perhaps you can disable them,
or perhaps limit the number of data points on the graphs? I would think
that the graphs slow down when you have too much data on them.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Marco Martin" <ma**********@sympatico.ca.antispam> wrote in message
news:Xy*********************@news20.bellglobal.com ...
Thanks Nicholas,

Thats exacly what I needed. Now I just have to figure out how I'm going to use this information.

I'm trying to do something like;

if(bolCrappyCPU || bolCrappyVideoCard)
{
//do something
}
else
{
//do something else
}

regards,

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

You can definitely get this. You can get almost any system information
you want using the classes in the System.Management namespace. Basically,
you can query for WMI classes (which are not .NET classes) which have the values that you want. You can get information about the processor, the
graphics card, etc, etc.

You probably want to look for instances of the Win32_Processor class

and
the Win32_VideoController class.

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

"Marco Martin" <ma**********@sympatico.ca.antispam> wrote in message
news:%x********************@news20.bellglobal.com. ..
Hi,

I developed an application on my workstation which is a P4 2.4G. Now that my application is almost finished, I find out that this app will be
used on
the road by technicians using laptops(gota love inter-office

communication).
This causes a *major* problem because my app is very UI intensive (its

got many graphs displayed in real-time) and tests on our own laptops show that they just cant cut it. (I'm not saying anything againts laptops,
beeing a big fan myself, its just that their graphics adapters aren't as

powerfull).

Anyway, I'm going to include two configurations of my program. A full
version for powerfull pcs, and another smaller, less intensive version for older pcs/laptops.

My question is, is it possible for my app to know if its running on a
laptop, or a PentiumII? Is there a way for me to know what CPU is running and at what speeds?

Thanks and best regards,

Marco



Nov 15 '05 #4
Definately. I'm wanting to turn them off, or maybe leave the option to see
one at a time. problem is, i have to find a way to take this information
and compare it to something. I'm just not sure what yet.

regards,

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

Since you said the graphs are the culprit, perhaps you can disable them, or perhaps limit the number of data points on the graphs? I would think
that the graphs slow down when you have too much data on them.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Marco Martin" <ma**********@sympatico.ca.antispam> wrote in message
news:Xy*********************@news20.bellglobal.com ...
Thanks Nicholas,

Thats exacly what I needed. Now I just have to figure out how I'm going

to
use this information.

I'm trying to do something like;

if(bolCrappyCPU || bolCrappyVideoCard)
{
//do something
}
else
{
//do something else
}

regards,

Marco
"Nicholas Paldino [.NET/C# MVP]" <mv*@spam.guard.caspershouse.com> wrote

in
message news:OJ**************@TK2MSFTNGP11.phx.gbl...
Marco,

You can definitely get this. You can get almost any system

information
you want using the classes in the System.Management namespace. Basically, you can query for WMI classes (which are not .NET classes) which have the values that you want. You can get information about the processor, the graphics card, etc, etc.

You probably want to look for instances of the Win32_Processor class
and
the Win32_VideoController class.

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

"Marco Martin" <ma**********@sympatico.ca.antispam> wrote in message
news:%x********************@news20.bellglobal.com. ..
> Hi,
>
> I developed an application on my workstation which is a P4 2.4G.
Now
that
> my application is almost finished, I find out that this app will be used on
> the road by technicians using laptops(gota love inter-office
communication).
> This causes a *major* problem because my app is very UI intensive

(its got
> many graphs displayed in real-time) and tests on our own laptops
show that
> they just cant cut it. (I'm not saying anything againts laptops, beeing
a
> big fan myself, its just that their graphics adapters aren't as
powerfull).
>
> Anyway, I'm going to include two configurations of my program. A

full > version for powerfull pcs, and another smaller, less intensive version for
> older pcs/laptops.
>
> My question is, is it possible for my app to know if its running on

a > laptop, or a PentiumII? Is there a way for me to know what CPU is

running
> and at what speeds?
>
> Thanks and best regards,
>
> Marco
>
>



Nov 15 '05 #5

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

Similar topics

1
by: Sami Viitanen | last post by:
Hello, I'm using os.popen and read for reading command input to string but the string doesn't contain the same output that running the command manually or with os.system contains. with...
303
by: mike420 | last post by:
In the context of LATEX, some Pythonista asked what the big successes of Lisp were. I think there were at least three *big* successes. a. orbitz.com web site uses Lisp for algorithms, etc. b....
4
by: Mark | last post by:
hey, i'm trying to get the current windows user and the groups they are in. Intergrated windows auth on and annoymous access turned off on IIS. However when trying to compile the following code...
3
by: Hitesh | last post by:
Hi, I am getting the response from another Website by using the HttpHandler in my current site. I am getting the page but all the images on that page are not appearing only placeholder are...
1
by: Nathan Sokalski | last post by:
I have retrieved data from a database using a SELECT statement that includes an INNER JOIN. The data seems to be retrieved to the DataSet OK, but I am having trouble getting the data from the...
4
by: Pat | last post by:
In my Web.config i have :- <customErrors mode="On" defaultRedirect="genericerror.htm"> <error statusCode="404" redirect="pagenotfound.aspx"/> </customErrors to get page not found error but...
1
by: John Wilhelm | last post by:
I'm having a problem in by VB.net 2005 application. When i try to get a node from my app.config file the node come back with "nothing". The xmldocment loads OK, but I can't retrive a node. The...
1
by: darrel | last post by:
I've been struggling for some time now getting a RSS app to work. I'm creating RSS from existing XML files (transforming via XSLT). The problem is that the page, itself, is still being sent at...
3
by: tshad | last post by:
I have a file that I converted from VB.Net to C# that works fine in VB.Net when I compile but not in C# using the same libraries. The error I am getting is: PageInit.cs(9,7): error CS0138: A...
15
denny1824
by: denny1824 | last post by:
I have a working website. I copied all the files to a new folder in inetpub/wwwroot and then set that folder as a Virtual Directory in IIS. I try going to that site from the new folder and i am...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
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
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
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
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,...
0
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...

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.