powershell - Get processor info with wmic - format error -


when try number of cores , logical processors in 1 shot, following error:

 ps c:\> wmic cpu numberofcores, numberoflogicalprocessors /format:list invalid expression. 

how can format correctly result want?

put list of field names in quotes , remove space between them:

wmic cpu "numberofcores,numberoflogicalprocessors" /format:list 

better yet, drop wmic , use get-wmiobject if you're using powershell anyway:

get-wmiobject win32_processor |     select-object numberofcores, numberoflogicalprocessors |     format-list 

Comments

Popular posts from this blog

ubuntu - PHP script to find files of certain extensions in a directory, returns populated array when run in browser, but empty array when run from terminal -

php - How can i create a user dashboard -

javascript - How to detect toggling of the fullscreen-toolbar in jQuery Mobile? -