Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!uwm.edu!psuvax1!psuvm!hcm100 From: HCM100@psuvm.psu.edu (Hans C. Masing) Newsgroups: comp.lang.pascal Subject: Re: Dose anybody have space det. code!!!!!!!!! Message-ID: <91120.151026HCM100@psuvm.psu.edu> Date: 30 Apr 91 19:10:26 GMT References: <1991Apr22.060051.2238@nuchat.sccsi.com> <1991Apr28.131624.7940@cc.curtin.edu.au> <1991Apr28.150459.631@cs.odu.edu> Organization: Penn State University Lines: 29 Here's my $0.02 worth towards the space detection procedure: (*--------------------------8< cut here-----------------------*) PROCEDURE Change_Spaces_to_Dashes (VAR InStr : String[40]); VAR I : Integer; (* Indexing variable *) BEGIN I := 1; While InStr[I] <> '' do Begin If InStr[I] = ' ' then InStr[I] := '-'; I := I + 1; End; END; (*--------------------------8< cut here-----------------------*) This should be very generic and work with most version of PASCAL, EBCIDIC or ASCII. Now, who's going to write a recursive version of this one? :-) Hans /_/ _ /| /| _ ' | HCM100 @ PSUVM.psu.edu _/ /_(_|_/|/_/)_ / |/ |_(_|_/)_/_/|/_(_) | Hans C. Masing (__/