How could I start a thread in a different session? I need to start a thread in the interactive session (session 1) from a service in the non-interactive session (session 0). I have done this with a process before by using SetTokenInFormation and DuplicateTokenEx and then passing this to CreateProcessAsUser. I was hoping I could do the same thing except use SetThreadToken instead of CreateProcessAsUser.
Threads don't belong to sessions, processes do. You'll need to create a process in the other session to host the thread you want.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With