HDTenEightyP/NetNews huggingface dataset:
From: k044477@hobbes.kzoo.edu (Jamie R. McCarthy)
Subject: Re: How to Get the Name of A File?
Organization: Kalamazoo College
Date: Tue, 14 Apr 1992 15:18:00 GMT

kevin@crash.cts.com (Kevin Hill) writes:
>
>  I am on the home stretch of my new program!!  BUT!
>
>   Ok here's the problem:
>
>     I have the DirID of the directory.
>     I have the volNum of the directory.
>     I don't have the name of the file. (problem)
>
>  I tried to use GetMacFileInfo to get the Finfo struct that would contain
>the name and type etc.. However, I get a -43 error.
>
>when I use ioFDirIndex to get the files in the directory,
>I again cannot figure out how to get the name of the files
>in the directory.  GetMacFileInfo again does not
>work, it crashes with -43 error.

I'm not sure I understand.  This is the same problem, right?  If you
have the dirID and volNum, you need one more piece of information to get
at the file, and if you don't know the name, it must be the dirIndex.
So you're trying to use a dirIndex to find your file?

CFile::GetMacFileInfo() relies on having the name of the file
set up properly;  it won't help you if you haven't specified the file.

Here's a little sample code that cycles through a directory.  I use
GetCatInfo, but the idea's the same.

Str63 myName;
OSErr theOSErr;
CInfoPBRec myPB;
myPB.hFileInfo.ioCompletion = NULL;
myPB.hFileInfo.ioNamePtr = myName;
myPB.hFileInfo.ioVRefNum = vRefNum;
myPB.hFileInfo.ioFrIndex = 1;
while (theOSErr == noErr) {
	Boolean isFile;
	myName[0] = 0;
	myPB.hFileInfo.ioDirID = dirID; // see IM4 p126.
	theOSErr = PBGetCatInfo(&myPB, FALSE);
	if (theOSErr == fnfErr || theOSErr == nsvErr) {
		break;
	} else if (theOSErr != noErr) {
		Debugger();
		break;
	}
	isFile = (BitTst(&myPB.dirInfo.ioFlAttrib, 3) == 0);
	if (isFile) {
		FInfo *theFInfo;
		theFInfo = &myPB.hFileInfo.ioFlFndrInfo;
	}
	++myPB.hFileInfo.ioFDirIndex;
}

That call to Debugger() is in there because I don't think any error
should be returned except an fnfErr (which indicates that there are no
more files in the directory) or an nsvErr (which would indicate a bad
vRefNum or dirID).

Note that you have to reset dirID each time through.  Contrary to a
comment in the UMPG Volume I, there _is_ a reference to this in IM;
it's just very well hidden.  :-)
-- 
 Jamie McCarthy     Internet: k044477@kzoo.edu     AppleLink: j.mccarthy
 "Almost all portables today employ passive-matrix LCDs, and no one expects
 active-matrix screens to be cost-competitive for a few years" -PC World 2/92
Newsgroups: comp.sys.mac.programmer
From: jbush@magnus.acs.ohio-state.edu (John E Bush)
Subject: Re: Problems with ResEdit2.1
Keywords: ResEdit, lockup
Organization: The Ohio State University
Date: Mon, 13 Apr 1992 12:08:30 GMT

In article <1992Apr13.084038.29113@unix.brighton.ac.uk> pdt@unix.brighton.ac.uk
 (taylor) writes:
>I have ResEdit 2.1 which seems to work fine except when I try to change the
>name or ID of a resource. Attempting to do this results in the machine
>locking up. I am using system 7.0 - does anyone else have this problem or
>have I got a duff version? Help!
>
>Paul Taylor

Paul,

The latest version of ResEdit is 2.1.1 and is available on Apple's ftp site.
I used to have the same problem that you are experiencing, but have not had
the problem since I upgraded versions.

Eric Bush
From: jfeldhouse@miavx3.mid.muohio.edu (Jim Feldhouse)
Newsgroups: comp.sys.mac.programmer
Subject: TCL, CDialog, Paramtext
Date: 13 Apr 92 23:49:26 GMT
Organization: as little as possible

I am trying to use CDialog with version 1.1 of TCL.
Currently I just wanted to mimic the following statements

				ParamText( numString, NIL_POINTER, NIL_POINTER, NIL_POINTER);
				Alert( 400, NIL_POINTER ); /* Get Unit Info Alert */

I was able to get the Dialog to appear but it seems to
ignore the ParamText statement.  Is this the case?
(that ParamText doesn't affect CDialog) and if so
what is a good way to work around it.

Currently I tried the following in my Talk2User method.

		// set up the dialog
NumToString( moves, numString );
ParamText( numString, NIL_POINTER, NIL_POINTER, NIL_POINTER );

		// show the dialog
BeginDialog();
	
		// run the dialog and return the final command.
DoModalDialog( cmdOK);


Thanks
Jim Feldhouse
From: mkelly@mystix.cs.uoregon.edu (Michael A. Kelly)
Newsgroups: comp.sys.mac.programmer
Subject: C.S.M.P. Digest v1 #46 Available
Date: 9 Apr 92 11:28:12 GMT
Organization: University of Oregon Computer and Information Sciences Dept.


C.S.M.P. Digest             Thu, 09 Apr 92       Volume 1 : Issue 46

Today's Topics:

	Bugs in Std. WDEF
	stepping a floppy head
	Macintosh speech recognition (was Re: Speech synthesis toolkit)
	THINK C 5.0.2 project file bug - don't mix Systems 6 & 7
	CMaster extension to THINK C
	Think C Q: Mixing SF dialog and ANSI file IO
	Window Storage?
	Floating windows: How to implement? PLEASE HELP!
	Advice for flickering text??


The Comp.Sys.Mac.Programmer Digest is moderated by Michael A. Kelly.

These digests are available (by using FTP, account anonymous, your email
address as password) in the pub/mac/csmp-digest directory on ftp.cs.uoregon.
edu.  This is also the home of the comp.sys.mac.programmer Frequently Asked
Questions list.

These digests are also available via email.  Just send a note saying that you
want to be on the digest mailing list to mkelly@cs.uoregon.edu, and you will
automatically receive each new digest as it is created.

The articles in these digests are taken directly from comp.sys.mac.programmer.
They are not edited; all articles included in this digest are in their original
posted form.  The only articles that are -not- included in these digests are
those which didn't receive any replies (except those that give information
rather than ask a question).  All replies to each article are concatenated
onto the original article in the order in which they were received.  Article
threads are not added to the digests until the last article added to the
thread is at least one month old (this is to ensure that the thread is dead
before adding it to the digests).

Send administrative mail to mkelly@cs.uoregon.edu.

-- 
_____________________________________________________________________________
Michael A. Kelly                                         University of Oregon
mkelly@cs.uoregon.edu                             Computer Science Department
_____________________________________________________________________________
From: ebido@bio.vu.nl (Etienne Bido)
Newsgroups: comp.sys.mac.programmer
Subject: cute diskdrive icons
Date: 13 Apr 92 23:48:45 GMT
Organization: VU Biology, Amsterdam, The Netherlands

I' ve noticed that when using some apps. or DA's there are two icons
for the internal and external drive. I like those icons because they
show which disk is in the internal/external drive. 
Is there a way to have the finder automatically use those icons when
you insert a disk?
I've been looking for them but I can't find those icons in the system
or he finder. Where are they stored?
I know that you can give each disk a different icon but they keep
that icon whether you put the disk in the int. or the ext. drive.

thanx!

-- 
Etienne Bido			|ebido@bio.vu.nl    
Vrye Universiteit		|bido@chem.vu.nl
Amsterdam
The Netherlands
From: beard@ux5.lbl.gov (Patrick C Beard)
Newsgroups: comp.sys.mac.programmer
Subject: Re: Dynamic INIT Loading
Date: 7 Apr 92 19:17:32 GMT
Article-I.D.: overload.1992Apr7.191732.26545
Reply-To: beard@ux5.lbl.gov (Patrick C Beard)
Organization: Berkeley Systems, Inc.

In article <BM50uA.5G8@world.std.com> zobkiw@world.std.com (Joe Zobkiw) writes:
#Here is an idea I've had in the past that may or may not work as planned.
#
#There are numerous times when I would like to load an INIT/Extension 
#without having to reboot my Macintosh. Now, I realize that some INITs 
#_depend_ on the fact that they are loading before the Finder has launched,
#etc...but...wouldn't it be cool to be able to automatically load (and
#maybe even unload) INITs dynamically?
#
#If we could only put them in their own heap (that _looked_ like the system
#heap to them)...hmmm...
#
#Any ideas?
#
#
#-- 
#<--------------------------------------------------->
# joe zobkiw                     zobkiw@world.std.com
# mac.synthesis.MIDI.development.C.asm.communications
#>---------------------------------------------------<


Watch out for my paper and talk coming up at MacHack this summer. I will
be discussing a technique for developing INIT's that lets you write them
as applications. The technique could easily be extended to load INIT's
dynamically. In fact, this  has been a dream of mine for some time.

If you can't attend MacHack, the code and paper will be available on the
CD-ROM.

I might event release early drafts of the paper to those who would feel
qualified to comment/criticize the techniques presented.

Patrick C. Beard
Berkeley Systems, Inc.
From: cshotton@oac.hsc.uth.tmc.edu (Chuck Shotton)
Newsgroups: comp.sys.mac.programmer
Subject: d e v e l o p
Date: 14 Apr 1992 15:13:22 GMT
Organization: UTHSCH Academic Computing

Has Apple stopped distributing "hardcopy" versions of d e v e l o p to
developers? I can't remember the last time I got one. It's a real pain to 
try and read those things on-line from the CD-ROM....

Chuck
Xref: sparky comp.sys.mac.programmer:7985 comp.sys.mac.apps:7750 comp.sys.mac.wanted:4336
From: bpb9204@tamsun.tamu.edu (Brent)
Newsgroups: comp.sys.mac.programmer,comp.sys.mac.apps,comp.sys.mac.wanted
Subject: Re: Fancy Your Tickle...
Date: 9 Apr 92 18:14:20 GMT
Followup-To: comp.sys.mac.apps
Organization: Texas A&M Univ., Inc.

time@ice.com (Tim Endres) writes:
|
|Tickle 3.1v4 is now available for general consumption.
| time e.

I had the version that was available in March and I have a question.
Is there some variables I need to set with it so that it can find
the scripts.  For example, when I give it some commands that are
documented in the tickle manual, it tells me that that command is
not found.  

Sorry this is general, but I'm not at my macintosh to check the settings.

I had the PATH variable set to the directories that contain scripts,
but this didn't seem to work (the path was set in the tclrc file, I believe).

Any hints are appreciated  and thanks for your work, Tim.

-Brent

-- 
------------------------------------------------------------------------------
Brent P. Burton, N5VMG                                    Computer Sci/Physics
bpb9204@tamsun.tamu.edu                                   Texas A&M University
------------------------------------------------------------------------------
Newsgroups: comp.sys.mac.programmer
From: russotto@eng.umd.edu (Matthew T. Russotto)
Subject: Re: Too many files open?
Date: Wed, 15 Apr 92 14:49:46 GMT
Organization: College of Engineering, University of Maryland, College Park
Keywords: Mac,error,file manager is a joy

In article <1992Apr15.041612.7835@clark.edu> day@william.vancouver.wsu.edu (Steve Day) writes:
>>
>On startup the system allocates a (limited, fixed) number of FCBs (File
>Control Blocks).  The number to be allocated is stored in the boot blocks
>of the startup drive and once they are set up the system can't create more
>as they are needed :-(  These blocks are also shared among all programs 
>including the system and finder and an application also counts as a file.
>I'm not sure if opening a resource fork and a data fork on the same file is
>considered one or two files (Anyone have an answer to that?).

Yes, they are considered two files.  System 7, and System 6 using an
extension called "Up your FCBs" allocate FCBs as needed, solving this
problem.


-- 
Matthew T. Russotto	russotto@eng.umd.edu	russotto@wam.umd.edu
Some news readers expect "Disclaimer:" here.
Just say NO to police searches and seizures.  Make them use force.
(not responsible for bodily harm resulting from following above advice)
From: roy@adeptsln.cts.com
Newsgroups: comp.sys.mac.programmer
Subject: Re: Garbage in my GWorld's - help!
Date: 10 Apr 92 19:34:52 GMT
Article-I.D.: adeptsln.1992Apr10.193452.2498
Reply-To: roy@adeptsln.cts.com
Organization: Adept Solutions

In article <1992Apr9.090415.13379@terminator.cc.umich.edu>  
krk@itl.itd.umich.edu (Kenneth Knight) writes:
> I am designing a program that does some fairly advanced graphics for work.  
The
> program is meant to provide an interactive means towards image compression
> (display both before and after images and let the user modify them). The  
image
> data are stored in Graphics World's (GWorld's). 

<< Much stuff deleted>>

Are you sure you are using SetGWorld & GetGWorld, and NOT SetPort & GetPort..  
(Even though GWorlds are typed as CGrafPtr's + stuff, you have to use the  
proper routines.)
This bit me a few years ago, (left a nasty scar :), but the reason that I  
remember about it to this day was that it ALMOST worked, but there was SOME  
GARBAGE!!! And it too seemed rather random..

Also, LockPixels is a big must, too!
-- 
Roy Lovejoy      | internet:  roy@adeptsln.cts.com
Head RGB Guy     | AppleLink: adept
Adept Solutions  | CIS:       72447,1447
.................| dual certified developer: NeXT & Apple ;)
From: Keith_Rollin@taligent.com (Keith Rollin)
Newsgroups: comp.sys.mac.programmer
Subject: Re: THINK C 5.0.2 questions on syntax
Date: 15 Apr 92 21:28:51 GMT
Organization: Taligent

In article <1992Apr14.120640.417@mr.gov.bc.ca>, cconstantine@mr.gov.bc.ca
writes:
> 
> I have a couple of questions on THINK C 5.02 syntax and procedures.  My first
> question has to do with MENU resources.  I'm compiling the first volume of the
> Mac Programming Primmer for THINK C to conform to the new 5.02 standard for
> some ppl that have requested it sent be sent to them.  Anyway, in most of the
> programs where menus are involed, they don't always keep a handle to ALL of
the
> menus. ie: they will have a handle to the Apple Menu & edit menu, but not the
> File Menu or Special Menu (both of which are accessed more than the rest!!!
Any
> particular reason for this???

I think the real question is why do those programs keep track of any menu
handles at all, as opposed to just some of them. I _never_ keep track of any
menu handles. I always get them when I need them by calling GetMHandle.

--
Keith Rollin
Phantom Programmer
Taligent, Inc.
From: mxmora@unix.SRI.COM (Matt Mora)
Newsgroups: comp.sys.mac.programmer
Subject: Re: Garbage in my GWorld's - help!
Date: 9 Apr 92 19:38:21 GMT
Article-I.D.: unix.34131
Organization: SRI International, Menlo Park, California

Are you erasing your gworlds before you are using them?

Matt


-- 
___________________________________________________________
Matthew Mora                |   my Mac  Matt_Mora@sri.com
SRI International           |  my unix  mxmora@unix.sri.com
___________________________________________________________
Newsgroups: comp.sys.mac.programmer
From: mike@zorch.SF-Bay.ORG (Mike Smithwick)
Subject: Quickdraw and Laserprinters
Organization: SF-Bay Public-Access Unix
Date: Fri, 10 Apr 1992 04:56:10 GMT

[]

I'm trying to do some QD stuff on a laserprinter, but single pixels are too
damned big on the thing. 1 pixel wide lines look like a highway. Is there a 
way to specify smaller pixels or thinner lines without shrinking down 
the entire drawing.

mike


-- 
"There is no problem too big that can't be solved with high explosives"-Rush

Mike Smithwick - ames!zorch!mike
From: anarch@bonaire.dartmouth.edu (The Anarch)
Newsgroups: comp.sys.mac.programmer
Subject: Help with color table animation
Date: 11 Apr 92 22:16:40 GMT
Organization: Secular Humanists from Hell


    Sorry if this is a FAQ, but I don't have time to follow this group
regularly.  I'm seeking info/advice/code/etc. for doing color table cycling.
I've spent the last few hours messing about with AnimatePalette and have
achieved exactly zero success.  Not a single flicker.  I can do it by manually
manipulating palettes or color tables, but I'd like to use the "official"
approach.  I don't really understand the nature of animating entries in
palettes and their realation to other colors and palettes in use.  If someone
could just explain that, I think I'd be on my way.  Please mail, and I'll
summarize.  Thanks much.

-- 
+-+-+-+-+-+-+-+-+-+-+-+anarch@bonaire.dartmouth.edu-+-+-+-+-+-+-+-+-+-+-+-+-+
   "The Walpurgisnacht has become synonomous with any general revelry, and
     particularly for the breaking out of demonic lewdness and disorder."
D I S C L A I M E R :   E V E R Y T H I N G   I   W R I T E   I S   F A L S E
Newsgroups: comp.sys.mac.programmer
From: orlint@vccsouth20.its.rpi.edu (Timothy Troy Orling)
Subject: Re: Think Class Library discussion list
Organization: Rensselaer Polytechnic Institute, Troy NY
Date: Mon, 6 Apr 1992 22:32:27 GMT

In article <1330008@hpgrla.gr.hp.com> jbm@hpgrla.gr.hp.com (Jim Moy) writes:
>>Is there a discussion list dedicated to the Think Class Library? If not I...
>>mind maintaining a mailing list and an archive here at Brown University.
>

For that matter, how about about comp.sys.mac.programmer.TCL ?
Besides, there are too many articles posted here already!

Somebody want to start the voting? Somebody at SPLASH ought to take the
initiative I think. (Who uses America Online anyway?)
-- 
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
|  Tim Orling (orlint@rpi.edu)         |  Is global warming really happening |
|  Materials Joining Laboratory        |  or is it just a long range solar   |
|  Rensselaer Polytechnic Institute    |  cycle we don't understand?         |
From: trimper@edsi.plexus.COM (Greg Trimper)
Newsgroups: comp.sys.mac.programmer
Subject: Re: d e v e l o p Issue 10 out?
Date: 15 Apr 92 00:03:08 GMT
Article-I.D.: edsi.1992Apr15.000308.1636
Organization: Enterprise Data Systems Incorporated, Appleton WI


Is d e v e l o p Issue 10 out?  I ask, as I sent in a renewal slip,
but my VISA was not charged as of last month, I it is spring,
and i don't have an Issue 10...


Greg Trimper   trimper@edsi.plexus.com
From: lsr@taligent.com (Larry Rosenstein)
Newsgroups: comp.sys.mac.programmer
Subject: Re: How do I find out if Multi-finder is running??
Date: 9 Apr 92 19:27:23 GMT
Organization: Taligent, Inc.

In article <1992Apr9.164156.7341@waikato.ac.nz>, ldo@waikato.ac.nz (Lawrence
D'Oliveiro, Waikato University) writes:
> 
> But why bother thinking up all these elaborate techniques? Just check
> for the presence of the OSDispatch/JugglerDispatch trap ($A88F). It's the
> technique Apple themselves use. You can't get any simpler, or more reliable,

As I recall, checking for the MF Temporary Memory calls requires more than
testing for the trap.  Didn't you also have to check a low-memory global to rule
out Switcher?
--
Larry Rosenstein
Taligent, Inc.
lsr@taligent.com
Newsgroups: comp.sys.mac.programmer
Subject: Background Compilation
From: awil2@cs.aukuni.ac.nz (Andrew James        Willmott       )
Date: Thu, 9 Apr 1992 23:03:29 GMT
Organization: Computer Science Dept. University of Auckland

Is there an update to Think Pascal 4.01 yet that allows compilation to take
place in the background? (When running system 7, of course.) I'm currently
working with a program that can take about seven minutes to compile from
scratch - it would be nice to be able to do something constructive while this
is going on, even if it's only reading news!

On a related note, the reason that these recompilations are such a pain is that
whenever I shift machines, Think Pascal seems to think it's necessary to
recompile the entire project from scratch. At first I thought that this was just
because different copies of runtime.lib and interface.lib were being used
whenever a different copy of TP was used to run the project. When I put copies
of these libraries inside the project folder however, nothing changed.

This kind of thing tends to be quite a problem at Auckland Uni because students
come in and grab whatever machine is available. (There aren't enough computers
available for everyone to have their own personal machine.) Hence if a class of
students are supposed to work some program they've been given (which is what
will be happening with the thing I'm working on), they're not going to be
impressed if everytime they sit down to do some work on it they're faced with a
seven-minute recompilation!

Anyone got any ideas on causes/fixes? Oh yes, and the background compile thing!

Cheers,

Andrew the perplexed.

* Andrew Willmott, Auckland University, New Zealand.
* e-mail awil2@cs.aukuni.ac.nz

-- 
>
> ------------- [Wibble]
>
From: mspace@netcom.com (Brian Hall)
Newsgroups: comp.sys.mac.programmer
Subject: Re: How to Get the Name of A File?
Date: 15 Apr 92 00:22:26 GMT
Organization: Netcom - Online Communication Services  (408 241-9760 guest)

In article <1992Apr14.104226.1649@crash.cts.com> kevin@crash.cts.com (Kevin Hill) writes:
>   I am using the class library of THink C
>
>   Ok here's the problem:
>
>     I have the DirID of the directory.
>     I have the volNum of the directory.
>     I don't have the name of the file. (problem)
>
Why not call CDataFile::GetName to get the name?


-- 
+-----------------------------------------------------------------------------+
| Brian Hall, Mark/Space Softworks                                            |
| mspace@netcom.com; Applelink, America Online: MarkSpace                     |
+-----------------------------------------------------------------------------+
From: neal@farallon.com (Neal Trautman)
Newsgroups: comp.sys.mac.programmer
Subject: Apple Installer and Compression
Date: 14 Apr 92 13:25:34 GMT
Organization: Farallon Computing, Inc.

I need to compress some files to fit on a
single diskette.  I also need to use Apple's
Installer to do auto-decompression and installation.

The only product I have heard of is VISE.
I don't think any of the other standard
compression utilities, StuffIt, Compact Pro, etc.
offer decompression in Apple's Installer.

Are there any others?  Any recommendations?
--
Neal Trautman
Timbuktu Lead Software Engineer
Farallon Computing, Inc.
neal@farallon.com
From: erh0362@tesla.njit.edu
Newsgroups: comp.sys.mac.programmer
Subject: Error Number to String Conversion
Date: 15 Apr 92 01:54:33 GMT
Organization: New Jersey Institute of Technology


	Is there a toolbox call that will convert an error number into an 
appropriate string? If so what? If not why not? Am I doomed to type in 
all the strings for every error I intend to check for?

Elliotte Rusty Harold		Department of Applied Mathematics
elharo@m.njit.edu		New Jersey Institute of Technology
erh0362@tesla.njit.edu		Newark, NJ 07103
Newsgroups: comp.sys.mac.programmer