There are days when I just hate KRL's string and message handling.
Just lost the better part of half an hour trying to figure out why, when I used
I kept getting error message 1429, "String Too Long." sMessage was only 21 characters long. Eventually, I did a STDECLLEN test of $MSG_T.KEY[] to see if it had somehow been changed to less than 20 characters. Nope, 80. Then I ran STRDECLLEN against sMessage... and discovered that it had somehow been changed from its original declaration size of 40 to... 120.
Yep. If the source string is declared longer than the destination string, you get this error, even if the contents of the source string are less than the declared length of the destination string. I'm not sure how I've been able to program in KRL for all these years without ever running into this error before... probably b/c I always set my string lengths to match up ahead of time.