You could specify the font in the DEFINE POPUP code in the Menu.MPR file to control the font type/size and then use the FONTMETRIC() function to get character height and multiply number of items X height. This will give you a pretty good approximation on the size of the popup in pixels.
>
>I'm trying to make a menubutton which is a combination of a commandbutton and a menu popup.
>
>I want to make the menu to appear either below or above the command button. I've already figured out to make the menu(popup) appear below the button, but to let the menu appear above the button i've to calculate the height of the menu popup since you can position the menu with the ACTIVATE POPUP "Popupname" AT nRow, nCol in where the nRow and nCol are respresent the upper left corner.
>
>The question is: How do i calculate the heigth of a menupopup regardless of the fonts used in the menu(popup).
>
>and
>
>Is there some other way to accomplish this task ?
>
>Thanks in advance
------------------------------------------------
John Koziol, ex-MVP, ex-MS, ex-FoxTeam. Just call me "X"
"When the going gets weird, the weird turn pro" - Hunter Thompson (Gonzo) RIP 2/19/05