Path: utzoo!utgpu!watserv1!watmath!att!att!emory!gatech!mcnc!duke!physics.phy.duke.edu!fang From: fang@physics.phy.duke.edu (Fang Zhong) Newsgroups: comp.sys.mac.programmer Subject: Multifile Selection Message-ID: <21735@duke.cs.duke.edu> Date: 2 Nov 90 19:27:39 GMT Sender: news@duke.cs.duke.edu Lines: 35 Nntp-Posting-Host: physics.phy.duke.edu I want to process multifiles from one folder in a program. I don't know how to do it in a real Macintosh way. However, I could not make things to work even in a simple way. The following is my code. I would appeciate for any help to point out a correct way. Fang ______________ char **files; files = (char **)malloc(50 * sizeof(char *)); for(i = 0; i < 50; i++) files[i] = (char *)malloc(64 * sizeof(char)); types[0] = 'TEXT'; i = 0; for( ; ; ) { SFGetFile(where, " ", nil, 1, &types, nil, &reply); if(!reply.good) break; files[i++] = reply.fName; } n = i; for(i = 0; i < n; i++) { subroutine(files[i]); ...... } _____________ -- Fang Zhong 1-919-684-8247 Duke University Dept. of Physics fang@phy.duke.edu Durham, N.C. 27706