Home > Archive > Programming with dBASE > October 2005 > creating menus on the fly









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author creating menus on the fly
Agbeniga David

2005-10-27, 7:28 am

is there a way to make a non-mdi form to show menu items added to a drop down after the form has been opened. from my expereience the form allows menu items to be created but it doesent show them.
Todd Kreuter [dBVIPS]

2005-10-28, 8:23 pm

"Agbeniga David" <agbenigadavid@yahoo.com> wrote in message
news:NL2n5Xt2FHA.1236@news-server...
>
> is there a way to make a non-mdi form to show menu items added to a drop

down after the form has been opened. from my expereience the form allows
menu items to be created but it doesent show them.

That is my experience as well. Spent some time reseaching trying various API
calls to get the menu updated with no luck. Can you build the menu before
the form opens, or at least enable/disable certain items as needed?

Todd Kreuter [dBVIPS]


Agbeniga David

2005-10-29, 1:23 pm

Todd Kreuter [dBVIPS] Wrote:

> "Agbeniga David" <agbenigadavid@yahoo.com> wrote in message
> news:NL2n5Xt2FHA.1236@news-server...
> down after the form has been opened. from my expereience the form allows
> menu items to be created but it doesent show them.
>
> That is my experience as well. Spent some time reseaching trying various API
> calls to get the menu updated with no luck. Can you build the menu before
> the form opens, or at least enable/disable certain items as needed?
>
> Todd Kreuter [dBVIPS]
>
>


yes i can build the menu before the form opens and enable and disable at will. the problem is that i want my child windows to be listed on the menu of my main application window (which is sdi) as they are opened. is this limitation with updating menus on
sdi forms a dbase plus flaw or a windows OS limitaion.
David Stone

2005-10-29, 8:23 pm

Agbeniga David wrote:

> yes i can build the menu before the form opens and enable and disable at will. the problem is that i want my child windows to be listed on the menu of my main application window (which is sdi) as they are opened.


As I recall, the new items will show up if you close and then re-open the main sdi form. You would have to consider any procedures that are called in the main form's onOpen event or over-ridden Open function (just use a form.custom_property flag to skip t
hem when it's for menu-updating), and you can minimize the
visual effect of the close/open sequence by bracketing it within the API LockWindowUpdate function. But on a fast machine, it's barely noticeable anyway.

David


David Stone

2005-10-29, 8:23 pm

David Stone wrote:

> You would have to consider any procedures that are called in the main form's onOpen event or over-ridden Open function


Forgot---also the main form's onClose, CanClose, etc..

David

Sponsored Links





Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive | Programming forum archive

Copyright 2008 droptable.com