469,903 Members | 1,671 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,903 developers. It's quick & easy.

Calculate height of context menu (Compact Framework)

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
Nov 16 '05 #1
0 1630

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

1 post views Thread by Asad Khan | last post: by
4 posts views Thread by Mohit Gupta | last post: by
reply views Thread by Chris | last post: by
8 posts views Thread by Dennis C. Drumm | last post: by
4 posts views Thread by ssg31415926 | last post: by
reply views Thread by bLur-edEn | last post: by
reply views Thread by Mike Eaton | last post: by
1 post views Thread by Waqarahmed | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.