R
Rob Mayo
How can I force a MeasureItem message for an owner-dramn menu item?
Here is the dilemma. I wrote a lovely little Component for owner-drawing all
the menus on a form and making them look like Office XP-style menus (mostly
an academic exercise). I came across a problem with another app I wrote,
which is using this Component. The app changes the text in the menu items
depending on what is selected in the app. The fisrt time the menu may be
show (when it calls MeasureItem), the menu is appropriately owner-sized to
the text. The next time the menu is shown, the text will be different (in
this case longer). Since MeasureItem is never called again, the menu cannot
be appropriately sized to the text. In this instance, it cuts off the text
of the longer menu text.
Is there any way I can force Windows to send this message again?
Any help is appreciated.
Thanks in advance
WALDO
MCP, MCAD, MCSD
Here is the dilemma. I wrote a lovely little Component for owner-drawing all
the menus on a form and making them look like Office XP-style menus (mostly
an academic exercise). I came across a problem with another app I wrote,
which is using this Component. The app changes the text in the menu items
depending on what is selected in the app. The fisrt time the menu may be
show (when it calls MeasureItem), the menu is appropriately owner-sized to
the text. The next time the menu is shown, the text will be different (in
this case longer). Since MeasureItem is never called again, the menu cannot
be appropriately sized to the text. In this instance, it cuts off the text
of the longer menu text.
Is there any way I can force Windows to send this message again?
Any help is appreciated.
Thanks in advance
WALDO
MCP, MCAD, MCSD