title: Is there a way to display a message at login screen if a device is not found on Windows?
body: <p>I am looking for a way if we can display a message on the computer screen if the mouse or keyboard is not detected by the system.</p>
  
  <p>I can get the status fine using the PowerShell however was wondering if this can used for constant monitoring.</p>
  
  <pre class="lang-bsh prettyprint-override"><code>if ((Get-WmiObject Win32_PointingDevice | Where-Object {$_.Description -match 'hid'}).Count -gt 0) {
      Write-Host "Mouse is connected"
  } else {
      Write-Host "Mouse not found"
  }
  </code></pre>