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

  1. Path: sparky!uunet!olivea!apple!jkc
  2. From: jkc@Apple.COM (John Kevin Calhoun)
  3. Newsgroups: comp.sys.mac.hypercard
  4. Subject: Re: Storing window name?
  5. Message-ID: <75954@apple.apple.COM>
  6. Date: 26 Dec 92 18:06:28 GMT
  7. References: <bobjen-171292160238@bobjenner.ntu.edu.au>
  8. Organization: Apple Computer Inc, Cupertino, CA
  9. Lines: 26
  10.  
  11.  
  12. In article <bobjen-171292160238@bobjenner.ntu.edu.au>
  13. bobjen@darwin.ntu.edu.au (Bob Jenner) writes:
  14. >I wish to save the name of a window opened using the "picture" command for
  15. >further manipulation.
  16. >
  17. >Can anyone tell me how to get the name of a picture window opened using the
  18. >"picture" command.
  19.  
  20. When a new picture window is opened, the Picture XCMD sends the message
  21. "openPicture" to the current card.  The first parameter to the openPicture
  22. message is the name of the new picture window.  In HyperCard 2.1, the
  23. openPicture message has a second parameter as well, which is the id of the
  24. new picture window.  So, you can capture the name of the window as follows:
  25.  
  26. on openPicture name,id
  27.   global listOfPictureNames
  28.   put the number of items in listOfPictureWindows into numPictures
  29.   put name into item (numPictures + 1) of listOfPictureWindows
  30. end openPicture
  31.  
  32. When a picture window is closed, the Picture XCMD sends a closePicture
  33. message to the current card.
  34.  
  35. Kevin Calhoun
  36. jkc@apple.com
  37.