Why is a Public Enumeration defined in App inaccessible?

Why does this Project say “App has no member ‘StatusOptions’” even though StatusOptions came up in the App. autocomplete options?


The code is based on a project I found while searching the forum for help with creating custom events.


APP at runtime is a METHOD - not the instance in the IDE designer
Its one spot where the name “App” in the designer doesnt help you at all as it fools you into thinking they are the same thing and they most definitely are not

And because the METHOD at runtime is preferred the compiler correctly says that what the APP METHOD returns, which is an instance of Application, has no such items as StatusOptions since it really doesnt

And to top that off there is NO way for you to say “refer to the App class in my project not the app method” - except by renaming your App instance

IF you rename the instance in the project from App to MyApp then things might make more sense

EDIT : <https://xojo.com/issue/56457>
I know there’s another one in feedback somewhere but either I cant see it or cannot find it

So another option for fixing it in this case would be to more the enumeration into a module and tag it as “Global” scope, since it would then be proceeded by the module name and not App.?

Thats another option

FWIW, I tend NOT to store things in the App. A module, to me at least, is a more logical place to put globals.