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

  • Home
  • SEARCH
  • 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 6041515
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T06:40:21+00:00 2026-05-23T06:40:21+00:00

We just moved our application from a MDI container to a single document interface.

  • 0

We just moved our application from a MDI container to a single document interface. Our users are used to using a “Windows” menu in the MDI parent to show windows side by side. We want to train them to right click on the Windows taskbar and use the window management functions there.

With Delphi applications we noticed that the windows shell leaves room for the hidden “Application” window. So if I only have two windows open it will arrange room for three. The Application window is not really shown but there is space left for it.

This is made worse by the fact that we have two different applications. If they only have one window open in each application and want to show them side by side windows will actually try to account for 4 windows.

So instead of seeing two windows each taking 1/2 of the screen I see two windows that take up 1/4 of the desktop and the rest of the screen is open.

I found that adding a line to hide the application window as my application starts up will fix this problem.

ShowWindow(Application.Handle, SW_HIDE);

Edit in case someone does not read
down to the answer. Based on Craig’s
answer below I am setting the windows
style to WS_EX_TOOLWINDOW instead of
hiding the window.
SetWindowLong(Application.Handle, GWL_EXSTYLE,
GetWindowLong(Application.Handle, GWL_EXSTYLE) or WS_EX_TOOLWINDOW);

My (original) questions is: Is this safe (hiding the application window)? I’m wondering if I may be breaking something else by hiding the Application window. Are there any side effect I need to be aware of? Is there a better way to solve this issue?

I’m using Delphi 2007. The issues seem to be consistent across Windows XP, Vista, and 7.

Update: Some of the answers seem to think the problem is with the Application forms icon being visible. That is not the case. I already have MainFormOnTaskbar set to true.

Also if you are testing this be aware that the Delphi IDE (only tested with 2007) makes things worse. Try this. Open the Delphi IDE and two instances of notepad. Minimize the IDE but have both notepads un-minimized. Right click on choose Show Windows Side by Side. You will see each notepad take up 1/3 of the screen. Close the IDE and choose Show Windows Side by Side again and each will take up 1/2 half of the screen.

  • 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-05-23T06:40:22+00:00Added an answer on May 23, 2026 at 6:40 am

    As long as MainFormOnTaskBar is true, you can fix the problem by adding this to your DPR:

    SetWindowLong(Application.Handle, GWL_EXSTYLE,
      GetWindowLong(Application.Handle, GWL_EXSTYLE) or WS_EX_TOOLWINDOW);
    

    Later versions of Delphi automatically include the WS_EX_TOOLWINDOW flag when they create the TApplication handle.

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

Sidebar

Related Questions

Just moved to subversion...from visual studio. I love it already! Can someone briefly explain
I have just moved from phase 1 to phase 2 of a project. In
I have just moved job and gone from VB 6 to VB.Net and found
I just moved over to the Visual Basic team here at work. What is
We just did a move from storing all files locally to storing them on
We have a JavaScript function named move which does just windows.location.href = any given
I'm researching using Mercurial for our companies source control system. One immediate requirement that
Ok, so I've read just about every resource possible on converting from SVN to
I've just moved to storing my sessions in a database. My PHP code uses
I have a developed a application that allows users to draw simple images on

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.