home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #31 / NN_1992_31.iso / spool / comp / sys / mac / hypercar / 4685 < prev    next >
Encoding:
Internet Message Format  |  1992-12-30  |  1.5 KB

  1. Path: sparky!uunet!pmafire!news.dell.com!natinst.com!cs.utexas.edu!uwm.edu!zaphod.mps.ohio-state.edu!swrinde!gatech!enterpoop.mit.edu!eru.mt.luth.se!lunic!sunic!news.lth.se!pollux.lu.se!syo.lu.se!loa
  2. From: loa@syo.lu.se (Lars-Olof Albertson)
  3. Newsgroups: comp.sys.mac.hypercard
  4. Subject: Re: Menu Question
  5. Message-ID: <1992Dec30.190027.7195@pollux.lu.se>
  6. Date: 30 Dec 92 19:00:27 GMT
  7. References: <92365.115447IO10702@MAINE.MAINE.EDU>
  8. Sender: news@pollux.lu.se (Owner of news files)
  9. Organization: Lund University
  10. Lines: 35
  11. Nntp-Posting-Host: kinetics-28.ldc.lu.se
  12.  
  13. In article <92365.115447IO10702@MAINE.MAINE.EDU> IO10702@MAINE.MAINE.EDU 
  14. (Merv) writes:
  15. > I have made my own menus in the menubar and I was wondering
  16. > how to enable them.
  17. > ie when the user chooses one, how do I make it do something,,,,
  18. > I don't have the development pack.  If I did, I probably could
  19. > answer my own question.
  20. > Thanks.
  21. > -Merv
  22. Hello 
  23. you have to write a "domenu" handler 
  24. on domenu What
  25.   if what = "your menuitem" then
  26.     your commands
  27.     exit domenu
  28.   end if
  29.   if what =  "Your next menuitem" then
  30.     your commands
  31.     exit domenu
  32.  end if
  33.  pass domenu
  34. end domenu
  35.  
  36. It is important that you have a pass domenu at end of the handler
  37. If you don't have one you can't use any other menu.
  38.  
  39. it is also possible to use menuMessage when you create the menu, but
  40. I think that domenu is easier if you do it for the first time.
  41.  
  42. Try to find a stack with a menu and look at the scripts. It is a useful
  43. way of learning.
  44.  
  45. Regards and a Happy New Year
  46. Lars-Olof Albertson
  47. loa@syo.lu.se
  48.