Re: parameters...
Hi Nex one more time,
Most of system parameters you can get from registry (in Win
). For instance this procedure returns the frequency of CPU in MHz:
DWORD CPUFreqFromReg()
{
HKEY hKey;
DWORD dwBuff;
LONG lreg;
DWORD dwfreq;
lreg = RegOpenKeyEx(HKEY_LOCAL_MACHINE, "Hardware\\Description\\System\\CentralProcessor\\0", 0, KEY_READ, &hKey);
if(lreg == ERROR_SUCCESS)
{
dwBuff = sizeof(DWORD);
lreg = RegQueryValueEx(hKey, "~MHz", NULL, NULL, (LPBYTE)(&dwfreq), &dwBuff);
RegCloseKey (hKey);
};
if(lreg != ERROR_SUCCESS)
{
dwfreq = 0;
};
return dwfreq;
};
For the CPU ussage try this link:
hxxp://www.google.lt/search?q=cache:84B48FRl_ZcJ:codeproject.com/system/cpuusage.asp+%22get+cpu+usage%22+c%2B%2B&hl=lt&ie=UTF-8
You should refer to MSDN and Google too
My best regards to Rumunia!