Path: utzoo!utgpu!jarvis.csri.toronto.edu!cs.utexas.edu!tut.cis.ohio-state.edu!ucbvax!hoptoad!tim From: tim@hoptoad.uucp (Tim Maroney) Newsgroups: comp.sys.mac.programmer Subject: Re: Listomania!! Message-ID: <9818@hoptoad.uucp> Date: 23 Jan 90 14:53:16 GMT References: <26163@cup.portal.com> Reply-To: tim@hoptoad.UUCP (Tim Maroney) Organization: Eclectic Software, San Francisco Lines: 28 I tried to mail this, but the address at the bottom of the message bounced. In article <26163@cup.portal.com> Arthur_P_Bebak@cup.portal.com writes: >/* add the string */ >SetPt(&theCell,0,0); >strcat(string,"Test1"); Strike one -- string has not been initialized, so strcat will give unpredictable results. Try strcpy instead. >CtoPstr(string); >LAddToCell(string,strlen(string),theCell,theList); Strike two -- you're calling a C string routine (strlen) on a string you just converted to Pascal. This will give unpredictable results. Strike three -- you're setting a cell that does not exist. You gave a dataBounds which had no rows, and did not do an LAddRow to create a row. The LAddToCell should work, but I wonder why you don't do an LSetCell instead? You're not really appending, after all. This is weirdly similar to the strcat/strcpy confusion above. -- Tim Maroney, Mac Software Consultant, sun!hoptoad!tim, tim@toad.com "Our newest idol, the Superman, celebrating the death of godhead, may be younger than the hills; but he is as old as the shepherds." - Shaw, "On Diabolonian Ethics"