>>>
>>> How do you call a CLICK EVENT from a Menu option?
>>> At the beginning of my program, I may need to run an
>>> option off the menu...
>>
>>IMHO, CLICK events shouldn't be called by a menu.
>>
>>If you need to do it, make sure that the object can either be referenced
>>by a property of your application object (oApp.myform) , OR make the
>>object PUBLIC (PUBLIC goMyForm). Then you can just call it
>>oApp.myform.cmdbutton.click()
>>
>>However, again IMHO, if the function called by the click is needed
>>outside the form, perhaps you should put the function in a procedure
>>file (eg. myProcs.prg) and SET PROCEDURE TO myProcs. Then you can call
>>the procedure either from the menu or the click event. (FYI, although
>>slightly less convenient, procedures run a little faster than object
>>methods)
>>--
>>Matt McDonnell
>>
>>Conventional Wisdom - "If it ain't broke, don't fix it."
>>Gates Wisdom - "If it doesn't work, sell it, and fix it later."
>
>Hi Matt... What I am trying to do is to call a SET DATA PATH FORM that
>is called off the MAIN MENU. If this is a new install, the SET DATA PATH FORM needs to be called at load time. I thought I would call it from the MAIN MENU. What do you think?
If I understand what you're doing, here's one way...
In the table? where your storing the path info, also have a flag which identifies if this is a new installation. Use your main application object to run a routine to check for the flag an if true, call that form before anything else is executed. You might also consider using a system flag as a property of the oApp which if true diables all functionality until the data path is set.
Does that help?
Matt McDonnell
...building a better mousetrap with moldy cheese...