0

In Delphi XE3 I have a form that gets an initial FormResize event and no more. If I resize the form by dragging a corner I get no FormResize event and any aligned controls do not move/resize. The form is BorderStyle: bsSizeable.

Rob
  • 3,315
  • 1
  • 24
  • 35
  • Can you provide a minimal example that exposes your problem? – LU RD Apr 16 '13 at 15:10
  • This will happen when `OnResize` is `nil`, or perhaps is set to an event handler other than the one you intend. – David Heffernan Apr 16 '13 at 15:13
  • I don't have a minimal example unfortunately. It is one of about 50 forms in a large project. It is the only one that seems to show the issue and is quite large itself. – Rob Apr 16 '13 at 15:13
  • 1
    Well, time to get to work and create an example. Otherwise this is a non-question. This might help: http://sscce.org/ – David Heffernan Apr 16 '13 at 15:15
  • Thanks @DavidHeffernan, I knew OnResize wasn't nil so I looked deeper into the VCL Dispatch mechanism ... and found I had message mapped WM_MOVE (to try and debug a previous oddity). – Rob Apr 16 '13 at 15:23
  • It seems unlikely that this will help anyone else. Do you really want to leave it here? – David Heffernan Apr 16 '13 at 15:26
  • As a testament to my stupidity? Could it just disappear silently into the waves.... – Rob Apr 16 '13 at 15:39
  • 2
    @Rob: You can delete your Q if you want to (you might need to delete your A first). – Andreas Rejbrand Apr 16 '13 at 15:57

1 Answers1

2

Answer: when you override WM_MOVE and WM_WINDOWPOSCHANGED which I had put into investigate something else (duh). Moral: Fix one bug at a time.

Rob
  • 3,315
  • 1
  • 24
  • 35
  • 2
    Maybe you also forgot some `inherited`? – Andreas Rejbrand Apr 16 '13 at 15:48
  • This could actually be a good question/answer combo, **IF** these details were exposed in the question. Without mentioning that you use `WM_MOVE` etc in your question, this all becomes meaningless to others. If you like, edit your question to include a small sample reproduction of the issue, and I would up-vote the question (answer already is). – Jerry Dodge Apr 17 '13 at 00:21
  • What could I add to the question without also giving the asnwer – Rob Apr 18 '13 at 08:46