home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!ogicse!das-news.harvard.edu!cantaloupe.srv.cs.cmu.edu!crabapple.srv.cs.cmu.edu!andrew.cmu.edu!jv0l+
- From: jv0l+@andrew.cmu.edu (Justin Chris Vallon)
- Newsgroups: comp.sys.mac.hypercard
- Subject: Message-passing question
- Message-ID: <gefDdzC00VokMNhUpJ@andrew.cmu.edu>
- Date: 8 Sep 92 11:09:51 GMT
- Article-I.D.: andrew.gefDdzC00VokMNhUpJ
- Organization: Senior, Electrical and Computer Engineering, Carnegie Mellon, Pittsburgh, PA
- Lines: 37
-
- Hi.
-
- I was wondering why the following hypercard script behaves as it does
- (using Hypercard 2.1):
-
- Stack script:
- function test2
- return "stack script"
- end test2
-
- function test
- return test2()
- end test
-
- Background script:
- function test2
- return "background script"
- end test2
-
-
- put test() places "stack script" in the message box. Changing function
- test to:
-
- on test
- send "put test2()" to this card
- end test
-
- causes an error (can't understand test2). Is there any way to call a
- message handler defined in the background script from a message handler
- defined in the stack script?
-
- Even removing the definition of function test2 from the stack script
- does not help at all. The help stack is unclear or incorrect about the
- defined behavior of the given scripts.
-
- -Justin
- jv0l+@andrew.cmu.edu
-