Post Reply 
Emu48 Edit a CSV File
01-10-2022, 04:01 AM
Post: #21
RE: Emu48 Edit a CSV File
(01-09-2022 08:39 PM)MNH Wrote:  
(01-09-2022 02:34 PM)DavidM Wrote:  SL3: Source string
SL2: Target string to be replaced
SL1: Replacement text that takes the place of target

targ: the text which will end up being replaced in the source string
new: the replacement text for each target encountered
len: the length of the target text (not the length of the source text)

The stack arguments, SL1 through SL3, don't correspond with the local variables targ, new, and len.
I think my problem is that I don't know, or are confused by, what should be on the stack to make REPLS work. I executed REPLS, and the program didn't remove the line feed character from the first extracted string. Also, the program ended up in an infinite loop.

To expand a bit on David's comments:

SL1 means Stack Level 1 - this should be the new text to replace the target string

SL2 means Stack Level 2 - this should be the text which is to be replaced

SL3 means Stack Level 3 - this should be the original string

In order to replace a line feed in the original string, use 10 (the ASCII code for LF) for SL2.

--Bob Prosperi
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
Emu48 Edit a CSV File - MNH - 12-30-2021, 07:24 AM
RE: Emu48 Edit a CSV File - MNH - 12-30-2021, 04:34 PM
RE: Emu48 Edit a CSV File - MNH - 12-30-2021, 10:30 PM
RE: Emu48 Edit a CSV File - DavidM - 12-31-2021, 10:54 AM
RE: Emu48 Edit a CSV File - MNH - 12-31-2021, 06:11 PM
RE: Emu48 Edit a CSV File - MNH - 01-01-2022, 04:41 AM
RE: Emu48 Edit a CSV File - DavidM - 01-04-2022, 03:48 PM
RE: Emu48 Edit a CSV File - MNH - 01-04-2022, 11:32 PM
RE: Emu48 Edit a CSV File - DavidM - 01-05-2022, 12:14 PM
RE: Emu48 Edit a CSV File - DavidM - 01-08-2022, 11:22 AM
RE: Emu48 Edit a CSV File - MNH - 01-08-2022, 04:41 PM
RE: Emu48 Edit a CSV File - MNH - 01-08-2022, 07:41 PM
RE: Emu48 Edit a CSV File - DavidM - 01-09-2022, 02:34 PM
RE: Emu48 Edit a CSV File - DavidM - 01-10-2022, 10:50 AM
RE: Emu48 Edit a CSV File - MNH - 01-09-2022, 08:39 PM
RE: Emu48 Edit a CSV File - rprosperi - 01-10-2022 04:01 AM
RE: Emu48 Edit a CSV File - DavidM - 01-10-2022, 12:41 PM
RE: Emu48 Edit a CSV File - DavidM - 01-14-2022, 04:25 PM
RE: Emu48 Edit a CSV File - MNH - 01-15-2022, 07:34 PM
RE: Emu48 Edit a CSV File - MNH - 01-04-2022, 11:06 PM
RE: Emu48 Edit a CSV File - John Keith - 12-31-2021, 06:51 PM
RE: Emu48 Edit a CSV File - MNH - 12-31-2021, 07:58 PM
RE: Emu48 Edit a CSV File - MNH - 01-04-2022, 11:39 PM
RE: Emu48 Edit a CSV File - Eric Rechlin - 01-05-2022, 03:22 PM
RE: Emu48 Edit a CSV File - MNH - 09-04-2022, 09:56 PM



User(s) browsing this thread: 1 Guest(s)