I invocker Active Member Aug 23, 2021 #1 I use MediaProjectionScreenShot to get screen shot First Time Work Fine But If I ask It again From starter service I get This Error java.lang.SecurityException: Invalid media projection The activity was Hiden when permission is granted B4X: Copy Sub mp_permissiongranted'screenshot Log("permissiongranted") Dim jo As JavaObject jo.InitializeContext jo.RunMethod("moveTaskToBack", Array(True)) 'hide activity end sub The Error is Hier B4X: Copy mp.init(0, 0, 0) I change it with B4X: Copy mp.init(GetDeviceLayoutValues.Width, GetDeviceLayoutValues.Height, 0) But The Same Error Is their a way To solve it (client & Server)
I use MediaProjectionScreenShot to get screen shot First Time Work Fine But If I ask It again From starter service I get This Error java.lang.SecurityException: Invalid media projection The activity was Hiden when permission is granted B4X: Copy Sub mp_permissiongranted'screenshot Log("permissiongranted") Dim jo As JavaObject jo.InitializeContext jo.RunMethod("moveTaskToBack", Array(True)) 'hide activity end sub The Error is Hier B4X: Copy mp.init(0, 0, 0) I change it with B4X: Copy mp.init(GetDeviceLayoutValues.Width, GetDeviceLayoutValues.Height, 0) But The Same Error Is their a way To solve it (client & Server)