[futurebasic] Re: [FB] Accessing a Help file

Message: < previous - next > : Reply : Subscribe : Cleanse
Home   : May 2004 : Group Archive : Group : All Groups

From: Brian Stevens <brilor@...>
Date: Sat, 22 May 2004 07:50:23 -0700
On May 22, 2004, at 6:03 AM, Barrie wrote:

>>
>> On May 21, 2004, at 6:59 PM, Barrie wrote:
>>
>>>>
>>>> On May 21, 2004, at 5:12 PM, George Beckman wrote:
>>>>
>>>>> Call with your help menu item:
>>>>>
>>>>> fn OpenFileWithApplication( ghelpFSSpec )
>>>>
>>>> Barrie,
>>>>
>>>> The FN referred to by George uses Apple Events to open the file. The
>>>> FN
>>>> can be found on the FB^3 R7 CD in /Examples/Donations/Robert P's
>>>> FavoriteExamples/Application-related/Openfile/(AEvent->Finder) and
>>>> also
>>>> in Alain's CodeStyler source.
>>>>
>>>> Brian
>>>>
>>>> --
>>>>
>>> Brian and George
>>> Absolutely unbelievable. I followed instructions like a parrot.
>>> Couldn't
>>> understand RP's FN but it all worked first time. Many thanks for a 
>>> very
>>> efficient conclusion.
>> George gave you the answer, I just nudged it along. Good to hear it
>> worked.
>>
>>
>>> Just one more thing. I have my instructions under the Apple menu and 
>>> I
>>> don't
>>> need the Help menu (with the balloon stuff). How can I get rid of it.
>>> It
>>> does not show up in PG:PRO.
>> I haven't written a PG:PRO app in a while(so I could be all wet on
>> this) , but I don't believe the PG runtime adds a help menu. If so, it
>> must be in your code.
>> The call is slightly different for carbon, so it might be framed in a
>> conditional compile like:
>>
>> #IF CarbonLib
>> err = FN HMGetHelpMenu( HelpMHndl, #_nil )
>> #ELSE
>> err = FN HMGetHelpMenuHandle( HelpMHndl )
>> #ENDIF
>>
>> You might start out looking for either of these help manager calls in
>> your code.
>>
>> Brian
>>
>>
> Thanks Brian, that is indeed the problem.
> The lines are in the "Tlbx Help Mgr.Incl" file which is INCLUDEd in 3 
> other
> header files.  I didn't want to dabble into the header files so I found
> alternative answers.
Maybe you found something that I didn't. The include, Tlbx Help 
Mgr.incl,  does NOT INVOKE an FN to create a help menu, it only DEFINES 
toolbox calls for use in a program. This means somewhere else there is 
a call that invokes the toolbox call to create the menu.



> 1) The help menu can be deleted with DELETEMENU (_kHMHelpMenuID).
Good you found a solution, but it would be better not to create it in 
the first place to avoid any flashing with its creation and subsequent 
deletion.


> 2) The MENU statement in the Reference Manual shows how to add items 
> to the
> help menu and this works fine.
> Thanks for the help.
> Barrie
>
>
> --
>