Help with technical information 607

Reference http://www.borland.com/devsupport/pascal/ti_list/TI607.html

The above sited support for printing includes a function GetMem which is
used to extract the printer driver, printer type, and port information.  The
coding appears to be in error, particularily the last line which includes
"s:=   ;"  I am lost as to how to make this function work and in general how
to print text.  Can any one shed some light on either this procedure or
printing in general?

function GetItem(var S:PChar): PChar;
      var
        P: PChar;
        I: Integer;
      begin
        i:=0;
        while (S[I]<>',') and (S[I]<>#0) do
           inc(I);
        S[I]:=#0;
        GetItem:=S;

        if S[0]<>#0 then S:=   ;
      end;