Xojo 2019r1 menu bar items

Unfortunately I have to note that there are always some problems with updating to a newer version of Xojo.
This time the update from 2018r4 to 2019r1 has disabled some menu items in my program. They don’t work anymore in the new version.
I only noticed it (coincidentally) recently.
I don’t understand how this is possible. It worked in all earlier versions and now suddenly it doesn’t work anymore.
In the release notes I cannot found any explanation of what have been changed with the menu bar items.

I assumed that an update does not affect the functioning of my existing programs, unless there was a major error in the previous version.
So I feel obliged to switch back to 2018r4 despite having paid for version 2019r1.


Did you post a Feedback report, with a sample project?

Can you create in a new project a simple way to display the trouble and share it ?

2019r1 links against newer macOS libraries. Things may behave differently without explicitly appearing in Xojo release notes.

I’ve seen another post about troubles with the EnableMenuItems event, but I can’t say I’ve had any issues. It seems the more “clever” tricks don’t want to work on the newer version. What does your EnableMenuItems code look like?

Info : My programs are created for Windows 7 and later.

My ‘EnableMenuItems’ is never called (executed) … even if it exists.
I loaded my program in 2018r4.
Set a break point on the first line of code in my ‘EnabledMenuItems’ event.
Start the debugger. When the window (with the needed menu bar) is opened the program executing stops at the break point.

I do the same thing (with the same program) in 2019r1, and the break point is never reached … ???


Did you check the property in the Inspector to ensure that the correct menubar is selected? I had one (only one!) app that had that changed to None when I moved the app to 2019r1.

Yes the menu selections are correct in the inspector.
Apparently the only menu bar that works is the one of the main screen.
All other windows opened from within the main window have no working menu bars.

I find this very bizarre …

do those other windows have a menu bar assigned ?

Yes they do.

The problem is that I cannot recreate the error. New code that I create works, in 2018r4 and 2019r1.

Something in my existing program together with a change in 2019r1 makes that the menu bars don’t work anymore.

What has changed in 2019r1 compared to 2018r4 in connection with menu bars ?


Don’t know if this is relevant or could be important to found the problem:
I have my program in 2018r4. It works fine.

I load this program in 2019r1 -> menu items are not working (only main window menu works).
I save the program in 2019r1.

I reload this saved program into 2018r4 -> I got a warning that I load a newer version into an older version.
I click on Proceed and load the program anyway.
The menu bars do work normal and correct.


Why ?

There a a lot of different explanations for what you describe.
Also, having a non working code allows the reader (here) to have data to work on (think about it, read carefully, etc.) and to eventually found what is wrong (if anything is wrong either in your project or in Xojo).
At last, there may be some code somewhere that explicitely may do what you see with non 2018r4 Xojo IDE and you forgot about it / your eyes do not saw that while searching why it does not works with 2019r1.

At last, creating a simple project (from scratch) usually help to resolve the problem at writing time (before sending it).

Nota: my fn keys stopped to work yesterday (but a press on the fn key and F1 or F2 - for examples - made it working…). It tooks me a minute earlier today to made them working the standard way, but I had hard time. I do not know why that happened (it never comes to me in the last 40 years…), so go figure how hard debugging can be even with experience and knowledge…

After intensive search I found the following :

In 2019r1 if a window is opened as type ‘Floating Window’ the menu bar items do not work.
I suppose this is a bug in Xojo 2019r1.

May I ask other users to test this, to confirm or deny that it is yes or no a problem in Xojo 2019r1 ?


You could file a bug report but I dont think thats supposed to work

Hello Norman,

Do you mean that a menubar is not supposed to work in a floating window ?
It was working in Xojo 2018r4.

See the Release Notes of Xojo 2019r1:

So there has been some change regarding floating windows in 2019r1… and it seems to be on purpose.
But I can’t say if that’s a good one or not.

I can
It makes menus work when there is a floating window
The IDE would not when you used the inspector & tools palettes as floating windows because of this

What I dont know is the specific extended window style in use for those
And thats likely relevant
I assume they use WS_EX_TOOLWINDOW
What I dont know is whether they are or are not child windows (WS_CHILD) as a child window cannot have a menu bar

see https://docs.microsoft.com/en-us/windows/desktop/winmsg/window-styles

Some more tests :

The default ‘MainMenuBar’ can be used in a Floating Window.
A user made MenuBar can’t be used in a Floating Window.

I have made two small projects to explain the problem, but I don’t know how to post these on this forum.

A feedback report has been posted.


Nothing changed in version 2019r1.1.
Menu still not works in a floating window.

without a release note saying they fixed it I’m unsurprised its not fixed in 2019r1.1

If you examine the use guidelines for a “floating window”, [generalized summary here] you’ll see that they are supposed to be used for app-specific popup windows that display information or options with relationship to the parent/main window. They shouldn’t have menus or taskbar/dock entries attached and shouldn’t be used as main windows in an application.

I’ve also used them improperly before and got bitten by this. I then looked into the various Window types and how they “should” be used and discovered the above (in far more words).