Article View: news.software.readers
Article #262860Re: 40tude find & replace 4 characters before sending message!!!!!!
From: Anton Shepelev
Date: Sun, 09 Sep 2018 10:55
Date: Sun, 09 Sep 2018 10:55
30 lines
1691 bytes
1691 bytes
VanguardLH:
> Pascal (on which Delphi is based) has its Re-
> placeStr() function. Maybe you could walk through
> each line in the message and pass that string to
> ReplaceStr() to replace all occurences of one
> character with another. You could have 4 Re-
> placeStr() commands, one for each Unicode charac-
> ter you are changing to the ASCII7 character.
That would be terribly clumsy and inefficient. Just
scan the string are replace offending characters in
one go:
begin
l := Length(s);
for i := 1 to l do
begin
case Ord( s[i] ) of
145: s[i] := Chr(39);
146: s[i] := Chr(39);
147: s[i] := Chr(34);
148: s[i] := Chr(34);
end;
end;
end;
--
() ascii ribbon campaign -- against html e-mail
/\ http://preview.tinyurl.com/qcy6mjc [archived]
Technical Details
Message-ID:
<pn2u68$10h0$1@gioia.aioe.org>Path:
mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!i2pn2.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.readers.(126883).mbox.7z!not-for-mailReferences:
<pn1qed$28a6$1@adenine.netfront.net> <1537aq73i3hah.dlg@v.nguard.lh>Show Full Headers
Complete Article Headers
Message-ID: <pn2u68$10h0$1@gioia.aioe.org> Subject: Re: 40tude find & replace 4 characters before sending message!!!!!! Date: Sun, 09 Sep 2018 10:55:04 +0000 From: Anton Shepelev <NaOnStPoAnM.txt@gmail.com> References: <pn1qed$28a6$1@adenine.netfront.net> <1537aq73i3hah.dlg@v.nguard.lh> Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!i2pn2.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.readers.(126883).mbox.7z!not-for-mail Newsgroups: news.software.readers Organization: Aioe.org NNTP Server Lines: 30 NNTP-Posting-Host: c02vlIY9RXv79svAkcC7wQ.user.gioia.aioe.org X-Complaints-To: abuse@aioe.org User-Agent: Xnews/5.04.25 X-Notice: Filtered by postfilter v. 0.8.3 X-Received-Bytes: 1631 X-Received-Body-CRC: 2762035645