Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8945185
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T12:11:31+00:00 2026-06-15T12:11:31+00:00

I have a strange scenario in a C++ builder 2010 project I have in

  • 0

I have a strange scenario in a C++ builder 2010 project I have in front of me. Every once in a while modal forms seems to end up behind the main form. It seems like this occurs if I have the main window, open a secondary window using a button on the main window and the selects a button on the main window that will produce a modal form popup. The modal form then ends up behind the main window and I have to press escape to close it.

Opening it again produces the desired outcome with the modal window on top.

Sometime once this is done it seems like the main window starts putting itself in front of every window. Not just its own modal or child windows but even Windows Explorer windows and other programs. Update: This occurs every time a modal window has ended up behind the main window and has been closed using escape. Only way to get the main windows to behave normal again is to restart the application.

I have checked and fiddled with the FormStyle and PopupMode properties of both the main window and the modal popup that was the initial problem. But it doesn’t seem to help.
The main window has

FormStyle: fsNormal
PopupMode: pmNone

Since the main window starts acting strange it feels like the issue is with the main window somehow. I tried specifically telling the modal window to use the main window as its parent and trying all settings and combinations of FormStyle and PopupMode without any change.

To add to this all of this is reported to have worked pre-Vista (yes this is an old and large application… hehe)

Update: The main culprit seems to be the Main Window that ends up on-top of everything. This causes the modal forms to end up behind it and look like something is wrong with them. This only happens the first time and reopening the modal form draws it in front of the Main Window. Even though the Main Window is still in front of everything else on the desktop. To add to the confusion, when the Main Window decides to start acting like this feels very random.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-15T12:11:32+00:00Added an answer on June 15, 2026 at 12:11 pm

    The problem turned out to be a combination of the known issues with modal forms ending up behind other forms. Google "delphi modal form hidden behind other form" or something similar and you will find a lot of info.

    Another contributing factor was the fact that an implementation to counteract these issues had been made to the application. This, along with changes to both Windows and VCL itself didn’t play ball very well. So I stripped all of the “now” unnecessary junk and rewrote how the application handled its windows and the issue was resolved.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a strange problem with IE. I have a sequence of forms on
I have a strange problem with in-app billing RESTORE_TRANSACTION command. Every request RESTORE_TRANSACTION request
I have strange scenario in which if I create database using SQL Server 2008
I have this strange scenario. I have a table having multiple rows (each generated
I have the following strange scenario with spring's transaction management: I have method A
I have to accomplish a strange peculiar scenario. Its described as follows: I have
I have a scenario which is causing strange behavior with WPF data binding and
I have the following scenario. We have a sharepoint 2010 web template to create
I have a strange problem with acceptance tests, capybara showing me only first scenario
Kind of a strange question, but here is my scenario: I have accidentally added

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.