How can I run the Android onCreateOptionsMenu function in my code, that is, without clicking on the options menu button on the phone?
Activity.openOptionsMenu(); doing the trick
Activity.openOptionsMenu();
Name it yourself, for example, in onCreate() . However, there is a problem, you cannot pass the options menu because parent activity does not make it available.
onCreate()
Source: https://habr.com/ru/post/904342/More articles:Problems accessing a bucket that does not use the US region with the .Net SDK - c #Is there a way to manually trigger the "Enter key" event in a text box? - javascriptHow to test facebook like button? - javascript"Compatibility-v4-r4.jar" is missing in Maven Repo - androidIntersection of two data sets (lists) - c #Parse HTTP Header URL Values: Quoting, RFC 5987, MIME, etc. - http-headersHow to open a PDF file, which is also a project resource? - c #make element fill in its parent- htmlHow to determine the time zone for a specific date-time in a specific place? - timezonehow to get non-rectangular shape using getImageData ()? - javascriptAll Articles