(if (it < 128) then ("Insufficient Video Memory. Video Memory in MB: " & (it as string)) else (“Video RAM OK”)) of ((numeric value of (first match (regex “\d+$”) of it) of ((select “adapterram from Win32_VideoController” of wmi) as string)) / 1048576)
On the machines that are failing: is there more than one “adapterram”? My laptop requires me to use “selects” instead of “select” with that WMI query as there are two adapterram results.
q: (select “adapterram from Win32_VideoController” of wmi)
A: AdapterRAM=1824163840
E: Singular expression refers to non-unique object.
q: (selects “adapterram from Win32_VideoController” of wmi)
A: AdapterRAM=1824163840
A: AdapterRAM
q: (if (it < 128) then ("Insufficient Video Memory. Video Memory in MB: " & (it as string)) else (“Video RAM OK”)) of ((numeric value of (first match (regex “\d+$”) of it) of ((select “adapterram from Win32_VideoController” of wmi) as string)) / 1048576)
A: Video RAM OK
E: Singular expression refers to non-unique object.
q: (if (it < 128) then ("Insufficient Video Memory. Video Memory in MB: " & (it as string)) else (“Video RAM OK”)) of ((numeric value of (first match (regex “\d+$”) of it) of ((selects “adapterram from Win32_VideoController” of wmi) as string)) / 1048576)
A: Video RAM OK
E: Singular expression refers to nonexistent object.
“integer values of selects…” instead of just “selects…”
That will work in the case where there are two adapterrram results but only one has a value associated with it. If you have boxes that return multiple apaaterram values it will probably not work.
Any more updates in this thread? Even using “integer values of selects” I still receive:
<multiple results; error>
Debugger on every one (sample >25) of these machines returning this value report:
q:(if (it < 128) then ("Insufficient. Video Memory in MB: " & (it as string)) else (“Video RAM OK”)) of ((numeric value of (first match (regex “\d+$”) of it) of ((integer values of selects “adapterram from Win32_VideoController” of wmi) as string)) / 1048576)
A:“Video RAM OK”
E:“Singular expression refers to a non-unique object”
OR
q:(if (it < 128) then ("Insufficient. Video Memory in MB: " & (it as string)) else (“Video RAM OK”)) of ((numeric value of (first match (regex “\d+$”) of it) of ((selects “adapterram from Win32_VideoController” of wmi) as string)) / 1048576)
A:“Video RAM OK”
E:“Singular expression refers to a non-unique object”
OR
q:(if (it < 128) then ("Insufficient. Video Memory in MB: " & (it as string)) else (“Video RAM OK”)) of ((numeric value of (first match (regex “\d+$”) of it) of ((select “adapterram from Win32_VideoController” of wmi) as string)) / 1048576)
A:“Video RAM OK”
E:“Singular expression refers to a non-unique object”
It needed a little work (“numeric value” --> “numeric values” and moving the division to a different place in the expression)… Try this:
q:(if (it / 1048576 < 128) then ("Insufficient. Video Memory in MB: " & (it as string)) else (“Video RAM OK”)) of ((numeric values of (first match (regex “\d+$”) of it) of ((integer values of selects “adapterram from Win32_VideoController” of wmi) as string)) )
the check suggested here is set to x GHz speed (i set it to 2.4 GHz) - however, this is not accurate enough, especially with laptops.
for example, this analysis gave the result that a 6-month old Lenovo T61 thinkpad is not eligible, since its CPU speed is only 2400 MHz.
However, the full CPU name is “2400 MHz Intel® Core™ i5 CPU M 520 @ 2.40GHz”, which is a pretty new one…
this also goes for several PC types - for example, a HP DX2400 desktop, which is about 1 year old, also failed the eligibility test (E2160 Core 2 1.8GHZ) - and this one is Vista ready…
this is without even going into AMD CPU’s…
i am thinking that MHz speed is not enough to evaluate CPU’s.
can anyone think of a better way to evaluate CPU eligibility?
(date (local time zone) of now - (month (first 2 of it as integer) & day_of_month (first 2 of last 5 of it) & year (last 2 of it as integer + 2000)) of (
if (exist key
"HKEY_LOCAL_MACHINE\HARDWARE\Description\System\" of native registry and exist value "SystemBiosDate
" of key "HKEY_LOCAL_MACHINE\HARDWARE\Description\System\
" of native registry) then value "SystemBiosDate
" of key "HKEY_LOCAL_MACHINE\HARDWARE\Description\System\
" of native registry as string else "
") )
the CPU check is almost exactly the same as the “Windows 7 Eligibility Information Analysis”, so a bit of disappointment there…
there seems to be many CPU brands / types (Core 2 / Core 2 Dou / Core 2 Quad / i3 / i5 / i7 / various AMD CPU’s etc.) that pure CPU speed is not enough for eligibility analysis.
this is without taking into account the “Windows 7 XP mode”…
from what i could find, there is a list posted at Tom’s Hardware that list Intel CPU’s supported by Windows 7, and which also support XP mode:
but, for the life of me, i cant figure out a way to include this info in the hardware analysis…
with 4000+ computers, going through all computers one by one and figuring which one is too old and which one only has core speed below 2400 MHz (but has 4 cores, for example) seems a bit tedious…
there seems to be no way but to include the CPU name and manually filter out all of the newer CPU’s with speed <1800 (or so).
another way may be a totally different approach - look at the total disk size, this will give a rough estimate of the computer age (for laptops <80 GB and for desktops <160 GB - probably too old)
that’s why I posted the system age relevance, so you can just use motherboard age to make the decision. For instance, if your hardware refresh cycle is 3 years, you can remove anything older than 1095 days from the upgrade list.
Here’s an export of my property. Save it as a text file named system-age.bes and import it into your console.
<?xml version=
"1.0" encoding=
"UTF-8"?> <BES xmlns:xsi=
"http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation=
"BES.xsd"> <Analysis> <Title>System Age</Title> <Description><![CDATA[<TABLE> <TBODY> <TR> <TD><FONT size=2> <P><BR>This analysis uses BIOS date to show the age of systems in your environment. It is limited to Windows OS.</FONT></P></TD></TR></TBODY></TABLE>]]></Description> <Relevance>(
if( name of operating system starts with
"Win" ) then platform id of operating system != 3
else
true)</Relevance> <MIMEField> <Name>x-fixlet-modification-time</Name> <Value>Wed, 05 May 2010 23:58:56 +0000</Value> </MIMEField> <Domain>BESC</Domain> <Property Name=
"System Age" ID=
"5"><![CDATA[(date (local time zone) of now - (month (first 2 of it as integer) & day_of_month (first 2 of last 5 of it) & year (last 2 of it as integer + 2000)) of (
if (exist key
"HKEY_LOCAL_MACHINE\HARDWARE\Description\System\" of native registry and exist value "SystemBiosDate
" of key "HKEY_LOCAL_MACHINE\HARDWARE\Description\System\
" of native registry) then value "SystemBiosDate
" of key "HKEY_LOCAL_MACHINE\HARDWARE\Description\System\
" of native registry as string else "
") )]]></Property> </Analysis> </BES>