Windows user console not logged in - alert

Does anyone know if it is possible to get an alert if console user is not logged in.
We have a number of guests on simple help where the user apps will only run when console logged in

Write a toolbox that can use the qwinsta command, if no logged in id/s then send an alert

Cheers for the pointer, I’ll take a look and see how far I get.
I’m looking for console not logged in and the qwinsta command reports that console is logged in, even when they are logged out