D
Derrick
I'm trying to calculate the height of a context menu in a manner that will
work in both the full framework (where the calculation is easier because of
the MeasureItem event of a MenuItem) and the compact framework (no
MeasureItem event, which is why I'm stuck).
I have a button that, when pressed, shows a context menu that the user is to
make a selection from. Right now, I am always showing the menu below the
button, but this is obviously not sufficient if the menu is taller than the
distance from the bottom of the button to the bottom of the form; in which
case I want to show the menu above the button. Anyone know how to calculate
the height of the Menu or MenuItem?
Thanks,
Derrick
work in both the full framework (where the calculation is easier because of
the MeasureItem event of a MenuItem) and the compact framework (no
MeasureItem event, which is why I'm stuck).
I have a button that, when pressed, shows a context menu that the user is to
make a selection from. Right now, I am always showing the menu below the
button, but this is obviously not sufficient if the menu is taller than the
distance from the bottom of the button to the bottom of the form; in which
case I want to show the menu above the button. Anyone know how to calculate
the height of the Menu or MenuItem?
Thanks,
Derrick