PreLoginAgent - Trust App

Hi guys,

I am looking for a bit of help please?

I am trying to create a pre-login agent in Xojo for MacOS, basically it is a password self service app that displays a button and then opens a web browser to the internal self service site.

I have created the actual application, that bit is fine, but in order to allow the app to run at the login screen I need to explicitly trust the app to run by using NSWindow setCanBecomeVisibleWithoutLogin and NSWindow orderFrontRegardless.

I have been able to do this in Xcode, but I can’t work out how I can do the same in Xojo…

I have looked up as much about it as I can find, but nothing has helped so far, is anyone able to offer any insight?

Just to make sure, the Xojo application is being launched before the user logs in, correct?

Otherwise I can see no other reason as to why these two functions would fail.

[quote=150313:@Sam Rowlands]Just to make sure, the Xojo application is being launched before the user logs in, correct?

Otherwise I can see no other reason as to why these two functions would fail.[/quote]

Hi Sam,

Yes the app should launch before the user logs in, at the username and password screen basically.

Hope that makes it clearer.

But does it?

If you were able to do it successfully with other means, why in the world are you going through the extra work to make it happen with a different tool?

Maybe he only got a “hello world” app to work and to recode his Xojo app in Xcode could be too timely and/or costly…

So the reason I was asking is because I was able to download a sample app from the Apple Developer site for a per-login agent. It was obviously programmed in Xcode, Xcode really isn’t my strong suite.

Is ok though, I bit the bullet and learnt how to do everything I needed in Xcode, so my application is all built and working.

Cheers anyway.