home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1993 #1 / NN_1993_1.iso / spool / comp / sys / mac / programm / 21049 < prev    next >
Encoding:
Text File  |  1993-01-08  |  953 b   |  37 lines

  1. Newsgroups: comp.sys.mac.programmer
  2. Path: sparky!uunet!zaphod.mps.ohio-state.edu!wupost!mont!mizzou1.missouri.edu!UC525655
  3. From: UC525655@mizzou1.missouri.edu (Mark Eaton)
  4. Subject: assigning a StringPtr to an array of Str255s?
  5. Message-ID: <16B50FE12.UC525655@mizzou1.missouri.edu>
  6. Sender: news@mont.cs.missouri.edu
  7. Nntp-Posting-Host: mizzou1.missouri.edu
  8. Organization: University of Missouri
  9. Date: Fri, 08 Jan 93 18:04:02 CST
  10. Lines: 25
  11.  
  12. I have a struct declared as:
  13.  
  14. struct someStuff
  15.     {
  16.     ...
  17.     str255  contents[99];
  18.     }
  19.  
  20. this struct is global.
  21.  
  22. from within a function I:
  23.  
  24.     PBGetCatInfo(myCInfoPBRec)
  25.     someStuff.contents[myCInfoPBRec.hFileParam.ioFDirIndex] =
  26.         myCInfoPBRec.hFileParam.ioNamePtr;
  27.  
  28. when I do this, I get the error 'cant assign to array'
  29. when I try to dereference ioNamePtr I get 'syntax error'
  30.  
  31. I know this will knock me on the head, but can someone tell me what Im doing
  32. wrong?
  33.  
  34. mark
  35.  
  36. btw Im using ThinkC 5
  37.