home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!cis.ohio-state.edu!zaphod.mps.ohio-state.edu!usc!cs.utexas.edu!natinst.com!bigtex!texsun!digi!jjacobso
- From: jjacobso@digi.lonestar.org (Jon Jacobson)
- Newsgroups: comp.sys.mac.programmer
- Subject: ThinkC project resource problems
- Message-ID: <1992Aug21.145255.8244@digi.lonestar.org>
- Date: 21 Aug 92 14:52:55 GMT
- Sender: jjacobso@digi.lonestar.org (Jon Jacobson)
- Organization: DSC Communications, Plano Tx.
- Lines: 33
-
- Fellow netters,
-
- I've been working on the ColorTutor project in Dave Mark's book 'Primer Volume 2' and
- have been having problems with the program recognizing its resource file. I'm running
- a tuned-up System 7 with ThinkC 5.02 on an LC II. The problem I'm seeing is that when
- the program is run the GetMenu() calls to load the menu handles for the popup menus
- return a zero handle. I created the resources using ResEdit 2.1.1 and have even recreated
- the resource file several times just to be sure it wasn't a typo or something. Yes, the
- menu ID stuff is correct, ResEdit 2.1.1 is smart enough to do that for me :^).
-
- As an experiment I modified the call to IsColor() to !IsColor() so that the Alert would
- always be displayed upon executing the program. What I found was that if I didn't include
- the MENU resources in the project resource file the alert would display correctly. If the
- MENU resources were included in the project resource file the alert was not displayed.
-
- To make matters worse after I'd been working on this for a while whenever I tried to execute
- the program I'd get the old "finder" Unimplemented Trap bomb. To be safe I reloaded ThinkC
- from my originals. Has anyone seen this kind of strangeness before or have a clue as to
- why I'm seeing such strange resource problems?
-
- I have been through the source code several times and I'm confident that everything is
- typed properly. The program "behaves" as long as you don't try the popup menus (of course
- it doesn't like 0x00000000 for menu handles).
-
- Thanks in advance for your help!
-
- Jon Jacobson INTERNET: jjacobso@digi.lonestar.org
-
- --
- Jon Jacobson |
- jjacobso@digi.lonestar.org | Tis better to program and never be published
- DSC Communications | than to have never programmed at all.
- Plano, Texas | -me (apologies to W.S.)
-