alfcen Well-Known Member Licensed User Longtime User Apr 5, 2011 #1 In an attempt to change screen orientation while an activity loads, my phone rebooted itself. Code: Sub Activity_Create(FirstTime As Boolean) p.SetScreenOrientation(0) End Sub Is it reasonable to assume that p.SetScreenOrientation(x) must not be placed inside Activity_Create, Activity_Resume and Activity_Pause? Inside Activity_Click the screen rotates as expected.
In an attempt to change screen orientation while an activity loads, my phone rebooted itself. Code: Sub Activity_Create(FirstTime As Boolean) p.SetScreenOrientation(0) End Sub Is it reasonable to assume that p.SetScreenOrientation(x) must not be placed inside Activity_Create, Activity_Resume and Activity_Pause? Inside Activity_Click the screen rotates as expected.
Erel B4X founder Staff member Licensed User Longtime User Apr 5, 2011 #2 Did it happen once, or is it consistent? Upvote 0
K kickaha Well-Known Member Licensed User Longtime User Apr 5, 2011 #3 As I understand it, if you put it in Activity_Create, Activity_Resume or Activity_Pause you would create an endless loop as changing the orientation calls these. Upvote 0
As I understand it, if you put it in Activity_Create, Activity_Resume or Activity_Pause you would create an endless loop as changing the orientation calls these.
alfcen Well-Known Member Licensed User Longtime User Apr 5, 2011 #4 Consistantly, Erel Thanks for your thoughts, kickaha. Upvote 0
Erel B4X founder Staff member Licensed User Longtime User Apr 5, 2011 #5 There is no known limit that restricts the usage of this method in Activity_Create. You should make sure not to call it with a different orientation each time. Setting the orientation to a specific orientation will not cause an endless loop. Upvote 0
There is no known limit that restricts the usage of this method in Activity_Create. You should make sure not to call it with a different orientation each time. Setting the orientation to a specific orientation will not cause an endless loop.
alfcen Well-Known Member Licensed User Longtime User Apr 5, 2011 #6 Thanks a lot for your help, Erel! Upvote 0