String replace

Dirk A

Member
Licensed User
Longtime User
Hello,

I've got a string that contains about 32kb of data . Throughout the string there are clusters of 'FF' blocks . I want to replace them using the
Code: Copy
str.replace
function, but afterwards when the string is written to a file I see that not all 'FF' blocks are replaced . Even though
Code: Copy
str.IndexOf("FF")
gives me -1

this is the replace command :
Code: Copy
 str = str.Replace("FF","AA")
 
What do you mean with "FF" ?
Two times the letter F or do you mean the FormFeed character ?
If FF means FormFeed you should use:
str = str.Replace(Chr(12), "AA")
or replace "AA" by something else depending on what AA means.

Best regards.
 
Upvote 0
Back
Top