Looks like all you really need is some error handling. If the ([WMIClass]“\\$target\root\default:stdRegProv”) expression throws an error such as RPC Server is Unavailable, there’s really no point in trying to run the rest of the code for that particular target.
↧