FrmCustomAlert has several problems with doing substitutions. The
substitution code makes some bad assumptions:

1) Some versions assume substitution strings will always have a length of 1
or more. If they don't, it writes past the end of a block in your heap.

2) Some versions assume that the total length of the final string after
substitutions will be greater than the total length of the initial string.
This means that if you include ^1^2^3 you must substitute a minimum of 6
characters.

3) FrmCustomAlert inserts substitute text into the final string by moving
the suffix text forward by the difference between the substitute string and
the token it replaces. This causes problems if the later tokens are
replaced with empty strings since 0 characters are substituted in for each
2-character token. I have seen failures when the last two tokens were
replaced with empty strings.

It is probably only safe to use FrmCustomAlert if you never use empty
substitution strings.

Bill Goodman
Cyclos


Reply via email to