Got a LiveCode personal license? Are you a beginner, hobbyist or educator that's new to LiveCode? This forum is the place to go for help getting started. Welcome!
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller
-
raugert
- Posts: 112
- Joined: Thu May 26, 2016 9:30 pm
Post
by raugert » Fri Jun 01, 2018 5:44 am
Note: I changed the title of the post for better clarity... I hope it ok..
I use the "systemWindow" command to keep my stack on top of other applications. When I open a dialog box like "answer file" or answer "yes" "no" to quit, the dialog box appears behind my application window. So to bring the dialog box to the front, I temporarily issue a systemWindow False command to my stack, but I get a "screen flash" when doing this. Is there another way to bring the dialog boxes to the front and leave the systemWindow true so I don't get the screen flash ? This only happens on Windows platform and not on Mac.
Code: Select all
case "Quit"
lock screen
if the hilite of button "Always On Top" is true then set the systemwindow of stack "vMIx Panel Builder" to false
answer "Do you really want to quit?" with "No" or "Yes"
if it is "Yes" then
send "quitMyProject" to stack "myApp" in 0 millisecs
end if
set the systemwindow of stack "myAppr" to hilite of button "Always On Top"
unlock screen
break
Last edited by
raugert on Fri Jun 01, 2018 11:57 pm, edited 3 times in total.
Livecode Indy 9.6.11 (Stable)
MacOS Sonoma 14.2
Xcode 15.0.1 SDK 17.0
-
richmond62
- Livecode Opensource Backer

- Posts: 10076
- Joined: Fri Feb 19, 2010 10:17 am
Post
by richmond62 » Fri Jun 01, 2018 6:46 pm
I wonder why your dialog box is appearing behind the main stack:
is it a home-made dialog rather than the standard one built into LiveCode?
-
raugert
- Posts: 112
- Joined: Thu May 26, 2016 9:30 pm
Post
by raugert » Fri Jun 01, 2018 8:44 pm
No, it's the standard Livecode dialog box. It only happens when I set systemWindow of my stack to true. Otherwise it appears in the front as normal.
Livecode Indy 9.6.11 (Stable)
MacOS Sonoma 14.2
Xcode 15.0.1 SDK 17.0
-
jacque
- VIP Livecode Opensource Backer

- Posts: 7389
- Joined: Sat Apr 08, 2006 8:31 pm
-
Contact:
Post
by jacque » Sat Jun 02, 2018 6:03 pm
A system window floats over everything else so it's to be expected that a dialog will appear behind it. When you change a window style, LC must destroy the old window and create a new one, which is why you see the flash. There is no way to ask the OS to change the style of an existing window, it has to be created new. A lockscreen won't help because screen locks only apply to the current window, and that one is about to be destroyed.
The only workaround I can see is to use a group in the system stack instead of a dialog. In other words, do everything inside the system window.
Jacqueline Landman Gay | jacque at hyperactivesw dot com
HyperActive Software | http://www.hyperactivesw.com
-
raugert
- Posts: 112
- Joined: Thu May 26, 2016 9:30 pm
Post
by raugert » Sun Jun 03, 2018 2:19 pm
Thank-you jacque,
That is a great explanation. I could easily create a group for a simple yes/no dialog, but when I ‘open or save’ a file, I use the “answer file” dialog. That would be more complicated to create from scratch. I think I’ll live with the flashing in that case..
Thanks for your help,
Richard
Livecode Indy 9.6.11 (Stable)
MacOS Sonoma 14.2
Xcode 15.0.1 SDK 17.0
-
jmburnod
- VIP Livecode Opensource Backer

- Posts: 2729
- Joined: Sat Dec 22, 2007 5:35 pm
-
Contact:
Post
by jmburnod » Sun Jun 03, 2018 2:44 pm
Hi Richard,
That would be more complicated to create from scratch
Yes, if you want save to/ open from anyplace.
You may decide for one destination/source folder in documents folder or in the folder of your app to save/open file without answer/ask file.
Best regards
Jean-Marc
https://alternatic.ch
-
karmacomposer
- Posts: 361
- Joined: Wed Apr 27, 2011 2:12 pm
Post
by karmacomposer » Mon Apr 27, 2020 8:42 pm
I am having the same problem.
In Windows 10, everything works perfectly in the editor. However, after building, ask and answer dialogs are hidden or behind other items in the stack.
How can I fix this? I need answer and ask dialogs to appear like they should.
I can't seem to find anything in the build options that would fix this.
Thank you for any help.
Mike
-
jacque
- VIP Livecode Opensource Backer

- Posts: 7389
- Joined: Sat Apr 08, 2006 8:31 pm
-
Contact:
Post
by jacque » Tue Apr 28, 2020 4:16 pm
Nothing has changed since the first responses. A system window floats above everything else, that's its purpose. Try the suggestion above, setting it to false before showing a dialog.
Jacqueline Landman Gay | jacque at hyperactivesw dot com
HyperActive Software | http://www.hyperactivesw.com
-
FourthWorld
- VIP Livecode Opensource Backer

- Posts: 10043
- Joined: Sat Apr 08, 2006 7:05 am
-
Contact:
Post
by FourthWorld » Tue Apr 28, 2020 6:14 pm
Are there examples of apps from major vendors in which systemWindow-level windows are in front of dialogs opened from such a window?
True, systemWindow is designed to have a window above all others.
But modal dialogs are also designed to be above all others. And given their role, it seems reasonable that a modal dialog opened from any window - even a palette, even with systemWindow true - would be in front of the window invoking it.
I'd flag this as a bug.
-
Xero
- Posts: 157
- Joined: Sat Jun 23, 2018 2:22 pm
Post
by Xero » Tue Mar 25, 2025 10:19 am
I know this is a thread from ages ago, but my Livecode community has just started doing this too.
I haven't changed anything anywhere (that I am aware of) and whenever I close the stack in the IDE, the "do you want to save" dialogue appears behind the stack, and I can't see it (and consequently click on it). I go to the Windows tray and click on the window for the stack, and then the dialogue appears on top of the stack, and I can close it down. This is the same for the dialogues I use for "answer" commands.
Annoying, but can be worked around with a few clicks.
This is the case for all stacks, old and new that never did this before.
Was this bug dealt with?
I wonder why it has just started...
XdM
-
bamakojeff
- Posts: 33
- Joined: Tue Dec 06, 2022 6:53 pm
Post
by bamakojeff » Wed Mar 26, 2025 6:12 pm
I believe that it's a problem with the backdrop (View->Backdrop) on Windows. When you bring up a modal dialog box (one that is meant to stay on top), they appear
behind the backdrop. Hence you can't see them. But you can bring them to the foreground by clicking on the Livecode icons in the dock, or clicking anywhere on the backdrop, or clicking on any of the Livecode titlebars.
If you turn off your backdrop, then the modal dialog boxes appear in the foreground like they should.
I just reported it:
https://quality.livecode.com/show_bug.cgi?id=24673