Quantcast
Channel: VMware Communities : Discussion List - All Communities
Viewing all articles
Browse latest Browse all 178097

How to Convert NumCPU to An int?

$
0
0

i need to get the number of vCPUs on a VM and then cast the value into an integer data type.

 

$cpus = [int]( get-vm sqlvm1 | select NumCPU)

 

However it is telling me it can’t convert the data type of NumCPU to an int.

 

any ideas?


Viewing all articles
Browse latest Browse all 178097


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>