Consultor Eletrônico



Kbase P57270: Error 6491. Windows XP Dialog Box Title Bar size problem.
Autor   Progress Software Corporation - Progress
Acesso   Público
Publicação   13/01/2005
Status: Verified

FACT(s) (Environment):

Progress 9.1D07
Windows XP

SYMPTOM(s):

Error 6491. Windows XP Dialog Box Title Bar size problem.

That is, a dialog-box with buttons along the bottom produces the error "**BUTTON Btn_OK does not fit in parent DIALOG-BOX Dialog-Frame. (6491)".

**BUTTON Btn_OK does not fit in parent DIALOG-BOX Dialog-Frame. (6491)".

Problem occurs when the code is compiled when using the XP theme

CAUSE:

The tests were run on XP professional with "Windows XP Style".

FIX:

The size of the dialog box frame created is 297 by 208 pixels.
This frame size includes the size of the title bar. 208 pixels is tall enough when compiled with the old Windows interface settings (title bar height equals
18) but with the XP settings (title bar height equals 25) it is not tall enough.

You will get the 6491 error running this code on XP on any version of Progress.
You need to make the frame big enough to fit all of the widgets plus the title bar height and borders.

The title bar is considered part of the frame height, so it's best to let Progress figure out the dialog box's size if you can.

We don't adjust frame heights for XP.

We only do that when the code was compiled with one title bar height setting and then run with another title bar height setting. For example, if you compile your r-code on Windows 2000 with 18 pixel titles and then run it on XP with 25 pixel titles we will add 7 to the frame height to adjust for the difference.
But if you compile and run on XP with 25 pixel titles, there's nothing for us to adjust.