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 1111809
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 17, 20262026-05-17T02:36:24+00:00 2026-05-17T02:36:24+00:00

I am using Delphi 2010. I have to set UseLatestCommonDialogs to False and additionally

  • 0

I am using Delphi 2010.
I have to set UseLatestCommonDialogs to False
and additionally set ofOldStyleDialog property of Open and Save dialogs to true
if I want that Open and Save Dialogs works in Windows 7
(otherwise they do not open at all).
It is also true that I reserve quite a lot of space for a stack:

{$M 16384, 60048576}

since I use recursive algorithms on large datasets.
Now I wonder what is the problem:

  1. New dialogs seem very space consuming, sometimes
    they work at the beginning and after a set of open and save
    dialogs executions it does not open dialogs any more
    (maybe also dialogs do not free memory after they are executed?)

  2. Is there a bug in Windows 7?

Anybody else experienced a similar problem?

It looks a little strange to work on Windows 7 with ancient dialogs
(they are even older that XP style, I think they look like in Windows NT).

Any suggestion will be very appreciated.

Thanks in advance.

  • 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-17T02:36:25+00:00Added an answer on May 17, 2026 at 2:36 am

    The default stack space allocation specified by $M is global to all threads in the process that don’t specify their own specific requirements. 60M is a lot for this, far more than almost any stack will ever grow to.

    The File dialogs are essentially a hosted version of Windows Explorer. They load up shell extensions into your process for things like thumbnails, column handlers, context menus, etc. As Windows grows more featured, both MS and third parties feel free to use more and more resources – including threads – to add more info asynchronously, without blocking the UI. A simple test with notepad.exe on my Windows 7 64-bit machine shows that it has 1 thread before the dialog, but 19 threads while the dialog is open. In a 32-bit process with a default stack reservation close to 60M, that would want to reserve over 1G, or over half the total address space accessible to 32-bit applications by default. If there’s much data being worked with in the application at all, it’s very easy to see one running out of address space through memory fragmentation – all the code from the EXE, system DLLs, etc. needs to fit in there somewhere too. 60M is simply too high a default stack reservation to expect to work without problems.

    Have you considered moving your deeply recursive computations in a thread you create? You’d need to use BeginThread() from System directly though, in order to explicitly specify the stack reservation.

    Alternatively, is it possible to try reducing the stack usage of your algorithms? If you’re allocating records or arrays on the stack, consider allocating them dynamically. If you have a function which recurs a lot (nested deeply) and has a lot of local variables, consider creating a record containing the locals and allocating it dynamically. If you’re depending on the recursion to sequence work (e.g. depth-first traversals of trees / graphs), consider using the recursion simply to sequence work (e.g. add nodes to a list), and do the real processing iteratively. And if necessary, look at redoing the algorithm to work with an explicit stack. Another advantage of having an explicit stack is that you can trivially switch to breadth-first when desired, by using a queue instead of a stack, a one-liner if the stack and queue implementations use a polymorphic interface.

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

Sidebar

Related Questions

I`m using Delphi 2009 and want to operate some XML data. I heard that
When using Delphi IDE, it will silently change SQLConnection.Connected to true when populating field
I'm using Delphi 6, and I want a database bound list box with multiselect.
I'm using standard Delphi constants DayMonday, etc and I want to convert them to
I am using Delphi 2010 to create a Windows service that will monitor several
In delphi 2009 I have a reference to a IInterface which I want to
I'm using Delphi and need to get the current Windows DNS server IP address
I'm using Delphi 2007. How can I put a GIF/PNG image on a BitBtn
I am using Delphi 7 and ICS components to communicate with php script and
I am using Delphi TApplication.OnException Event to catch unhandled exceptions This works well but

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.