using ui elements behind a lock screen - possible?

So I have a script that I want to develop that uses specific UI elements of an application that it needs to run.

Is it even possible to run these UI elements if the screen is locked?