FileHandles to string

From: Andrew (arobcorp_at_yahoo.com.au)
Date: 07/10/04


Date: 10 Jul 2004 10:18:19 -0700

Hi all,
I am having trouble opening a file and displaying its contents. I have
built into the code test strings and tried to display them, and all
have no output (i am assuming that is because they are all
null-pointers), and the code is part of a cgi.
Any help would be appreciated, the code is below, and the lines
commented out are the ones crashing!

    open(File, "> /someWhere/My.txt") || die $errorString="can't
open";
    @ThreadPairs = <File>;
    foreach $items(@ThreadPairs){
        ($ThreadPosition,$ThreadName)=split(/=/,$items,2);
        $fields{$ThreadPosition}=$ThreadName;
        }
    if($fields{Thread} == 2){ $tempTest="yes"}
    $finalCount = "1" + $fields{Thread};
    for($PosCount = 1; $PosCount < $finalCount; $PosCount++){
        $tempThreadPos = "Thread"."$PosCount";
        $tempThreadName = $fields{$tempThreadPos};
        }
     close(File);
     }

thanks All
Andrew



Relevant Pages

  • Re: FileHandles to string
    ... > I am having trouble opening a file and displaying its contents. ... > built into the code test strings and tried to display them, ... You are opening the file for writing. ...
    (comp.lang.perl)
  • FileHandles to string
    ... I am having trouble opening a file and displaying its contents. ... built into the code test strings and tried to display them, ...
    (comp.lang.perl)
  • FileHandles to string
    ... I am having trouble opening a file and displaying its contents. ... built into the code test strings and tried to display them, ...
    (comp.lang.perl)
  • Some Forms Not Displaying
    ... Some forms are not displaying in a db I set up, but haven't seen for a while. ... It is used by the office I built it for. ... duplicating itself, but they were unable to pay me to look into it. ... When I checked the database's properties, the Statistics tab showed that the ...
    (microsoft.public.access.forms)
  • Re: Using VBA to replace text
    ... I built a function that tests for the TitleMaster and ... returns a "No" if there is none after displaying the presentation ... Prev by Date: ...
    (microsoft.public.powerpoint)