Screen rotation problem

Why does this not work?
What am I doing wrong?

because the screen orientation property does not change
therefore you should use the following logic

if screen.width > screen.height 
then "screen is landscape"
else "screen is portrait"


Trying to push the limits! Snippets, Tutorials and Extensions from Pura Vida Apps by icon24 Taifun.

1 Like

Sounds great, I'll try it.
Just one question, what is the point of the .ScreenOrientationChanged block if the screen orientation doesn't change?

Looking at the tool tip for this block, its text values are all in lower case.
Your test value is Capitalized.
Try changing that to "landscape".

P.S. Taifun's test is better. This block says what you want, not what it is.

see the documentation User Interface


Declares the requested screen orientation, specified as a text value. Commonly used values are landscape , portrait , sensor , user and unspecified . See the Android developer documentation for the complete list of possible options.