Hi.
I need a way to bypass the lockscreen and show the app.
I've tried using WindowManager and setting a flag - "SHOW_WHEN_LOCKED" in a custom library but obviously I'm doing something wrong.
here is the code I've tried to use:
When I run it I get a null reference exception...
What am I doing wrong?
Thanks in advance.
I need a way to bypass the lockscreen and show the app.
I've tried using WindowManager and setting a flag - "SHOW_WHEN_LOCKED" in a custom library but obviously I'm doing something wrong.
here is the code I've tried to use:
B4X:
public void Unlock (final BA ba){
Window layoutparams = ba.activity.getWindow();
layoutparams.setFlags(WindowManager.LayoutParams.FLAG_SHOW_WHEN_LOCKED, WindowManager.LayoutParams.FLAG_SHOW_WHEN_LOCKED);
}
When I run it I get a null reference exception...
What am I doing wrong?
Thanks in advance.