How do I enable popups from Task Scheduler

1 view
Skip to first unread message

T

unread,
Nov 12, 2022, 4:07:29 AM11/12/22
to
Hi All,

Windows 11 Pro 22H2

I wrote a program that will pop up various pieces of information
(MessageBoxW from user32).

When run from a command shell or an icon on the desk
top, the pop ups run fine.

But no pop ups when run from the Task Scheduler.

How do I configure the Task Scheduler for the pop ups?

Many thanks,
-T

T

unread,
Nov 12, 2022, 6:15:53 AM11/12/22
to
I got told this on another group:

In order to display a user interface tasks
must be configured to run only when the user
is logged on. Otherwise they will run in
non-interactive session 0 and any user
interface they attempt to display will not
be visible.

My program must be run as administrator. The user
is not logged in a administrator

What now?

T

unread,
Nov 12, 2022, 7:46:21 AM11/12/22
to
I figured out what I am going to do.

My program write a two line log file with the
date and time and the status every time it runs.

Since the user has to be logged in to see the
alerts, I will write a second program (ran as
the user when logged in) that picks up that
log file and sends pops up accordingly. And
run it five minutes after the first program.

T

unread,
Nov 12, 2022, 7:47:46 AM11/12/22
to
On 11/12/22 03:15, T wrote:

JJ

unread,
Nov 12, 2022, 8:41:14 AM11/12/22
to
If the user is an Administrator type instead of Standard User type, simply
tick the "Run with highest provileges" checkbox. That's all.

However, if the user is a Standard User type, Microsoft psexec's `-i 1`
command line switch is supposedly for solving this problem, but apparently
is not working properly. In Windows 7, even though the program has been
shown on the taskbar and its window is responsive to mouse/keyboard inputs,
its window content fails to be drawn - leaving ghost images from other
application windows which were overlapping its window boundary. In Windows
10, the program's window is not even visible on the taskbar. I think psexec
need some bug fixing.

T

unread,
Nov 12, 2022, 8:47:36 AM11/12/22
to
It looks like WTSSendMessageA will work.
Now to code it for Raku

T

unread,
Nov 12, 2022, 8:48:22 AM11/12/22
to
Did not work for me

>
> However, if the user is a Standard User type, Microsoft psexec's `-i 1`
> command line switch is supposedly for solving this problem, but apparently
> is not working properly. In Windows 7, even though the program has been
> shown on the taskbar and its window is responsive to mouse/keyboard inputs,
> its window content fails to be drawn - leaving ghost images from other
> application windows which were overlapping its window boundary. In Windows
> 10, the program's window is not even visible on the taskbar. I think psexec
> need some bug fixing.


Reply all
Reply to author
Forward
0 new messages