Gerard has asked for the wisdom of the Perl Monks concerning the following question:
But received the message unable to open the file. As it worked fine before I put the variable in I know it has something to do with this. I have tried escaping the characters but I am obviously doing something wrong. I am sure there is a simple answer, but I have looked for ages, and just feel really stupid. I would greatly appreciate it if some wise monk would impart some of their wisdom to me. Cheers, Gerard.#set the initial values for the text boxes to the first contact's det +ails #cd32/ is the directory $searchcontacts = "cd32/*.cd"; @allcontacts = <$searchcontacts>; $count = "0"; #display the first files contents first open(DAT, $allcontacts[$count]) || die("Could not open file!"); @allcontactdetails=<DAT>; close(DAT);
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Adding Files in a directory to an array
by davorg (Chancellor) on Oct 09, 2001 at 13:21 UTC | |
by jeroenes (Priest) on Oct 09, 2001 at 15:10 UTC | |
|
Re: Adding Files in a directory to an array
by Caillte (Friar) on Oct 09, 2001 at 13:18 UTC | |
|
Re: Adding Files in a directory to an array
by busunsl (Vicar) on Oct 09, 2001 at 13:25 UTC | |
by Gerard (Pilgrim) on Oct 09, 2001 at 15:29 UTC |