Ariel Constenla-Haile wrote:
what do you mean by "menu handlers"? Something handling the execution of menu items in a menu on a menu bar? the command URL assigned to a menu item (whose protocol can be "macro:///Library.Module.Subroutine")
Yes that is what I am referring to.

Create a menu via Tools > Customize for an embedded form - you only do so for ALL forms - At the moment in the basic procedure if you use thisComponenet what you get is a reference to the instance of the actual form on the desktop. With the change you will get the reference to the odb file that contains the definition of the form.

OK - reality this is a bit of a kludge - what really should happen is that the call to the procedure should have an event structure but for menus this is not the case - so this easy workaround. Yes, I know that there are other ways to get at the actual form - thisComponent is actually a shortcut anyway.

But all that said - It seems each time I think about this I am less concerned anyway - because:

  1. There isn't anything I can think of off the top my head that could
     not be handled if the change is made.
  2. I almost never use it this way for my own stuff.
  3. Looking at some of the basic code postings on OOoForum where folks
     used thisComponent  so far haven't seen one where I couldn't
     quickly change it over  without a problem that I can see [meaning
     I can't really test it]. ( I only looked at 6 and will try to
     browse a few more but doubt I'll find one that is a problem )
  4. It would be nice to have a shorthand way to get a reference to the
     database document anyway...



Drew




Reply via email to