home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #16 / NN_1992_16.iso / spool / comp / sys / mac / programm / 13053 < prev    next >
Encoding:
Internet Message Format  |  1992-07-27  |  1.3 KB

  1. Path: sparky!uunet!sun-barr!ames!agate!mar
  2. From: mar@ocf.berkeley.edu (Michael A. Ramirez)
  3. Newsgroups: comp.sys.mac.programmer
  4. Subject: Creating and Using folders??
  5. Date: 27 Jul 1992 16:28:20 GMT
  6. Organization: U.C. Berkeley Open Computing Facility
  7. Lines: 26
  8. Distribution: world
  9. Message-ID: <151874INNj75@agate.berkeley.edu>
  10. NNTP-Posting-Host: earthquake.berkeley.edu
  11.  
  12. Here is an easy question for some MAC programmer. I am trying to create a
  13. directory in my current working directory, and then set my working directory
  14. to that directory I just created. I have tried to use PBOpenWD, but to no
  15. avail. Here is what I have tried:
  16.  
  17. GetVol(volName,&vRefNum)
  18. volInfo.ioVRefNum=vRefNum;
  19. volInfo.ioNamePtr=nil;
  20. volInfo.ioWDIndex=0;
  21. volInfo.ioWDProcID=0;
  22. volInfo.ioWDVRefNum=0;
  23. PBGetWDInfo(&volInfo,FALSE);
  24. volInfo.ioNamePtr=DIRECTORY_NAME;
  25. PBOpenWD(&volInfo,FALSE);
  26.  
  27. Also I want to have the this also work if the directory is already present.
  28.  
  29. Any help will be appreciated.
  30.  
  31. Michael Ramirez
  32. mar@ocf.berkeley.edu
  33. -- 
  34. -----------------------------------------------------------------------------
  35. ___    _   ___ ___ _  ____  ____  ____   mar@ocf.berkeley.edu
  36. |__|  |_|  |  |  | |  |___| |___    /    When laws are outlawed then only
  37. |  \ |   | |  |  | |  |  \  |___  /___   outlaws will obey the law- Mondo 2000
  38.