Mike, If you can give a little more detail as to exactly what you are trying to do then maybe I can help. I have dome some pretty deep string manipulation between C-more and Do-more.
Basically "duplicating" the functionality of an old Giddings and Lewis system that I don't get to see the original code of. I looked at using the C-more recipes, but frankly keep shying away from them. I like the idea of the recipes living in the PLC better.
So the issue area gets down to the lacking text input functionality in the C-more. I am using the User qwerty keyboard with a few tweaks to give more symbols (and I originally had no comma, but I can't remember what it was inputting.) That's another issue as an aside. I copied it and modded it and now I can use the copy, but can't find it in the keypad screens anymore.
So I am wanting to have the operator allowed to enter a recipe description of no more than 40 characters. I then create a date and time stamp string from the PLC clock and append what the operator entered. All 60 recipe numbers and time-stamped descriptions are on one screen simply as a recipe parts list. The desired recipes for a job are entered by the 1-60 numbers (any 5 in any order even duplicated, 0's for unused.)
All of that is working properly, except I can't limit the C-more string to 40 characters per franji1's advice. OK, I can, but I have to be very careful how I handle it afterwards because it is highly infectious towards other strings. Oh, and if anything bad happens there's a trail of evidence pointing straight to me.
I did look at some kind of event handling but every time I had another ah-ha idea it had already been anticipated and blocked. Pretty frustrating.** At this point I will probably just snip it in the PLC and be done with it.
And on the Run screen, where the 5 (or less) "chosen" parts reside, I strip off the time stamp and just show the description the operator entered.
So I guess I have enough of a handle on this at the moment that I am moving on to the extraneous I/O logic and the other 2 servo CTRIO2's. The real booger was wrapping my head around
blending those chosen recipes into a linear progression through a machine. It's more like scheduling than anything else, no steps can be missed because you can't go back, you can never go back. Well, until the last piece of the order drops off and then you can back the hopefully still unblemished material out 20-30 feet.
Anyway, I tend toward verbosity rather than succinctness.
Thanks plcnut. I've played with strings in QuickBASIC and others a good bit, mostly long ago. The Do-more terminology is a little different but seems to work well for this.
And thanks HOST! I am pretty amazed when I look at how little code I have actually written to get some pretty powerful results. And still at 1.2mS max so far. I'm not the best planner in the world, I much prefer the just try it and see approach. The Do-more makes this pretty painless indeed. I have actually found myself looking at what the logic churned out to make sense of the numbers. It was usually easier than Excel though I used it extensively trying to understand the pattern I needed to see.
*(especially after I finally realized all of the Ctrl-C Ctrl-V's I had done were indeed being processed - even though I was clicking on the pushbutton object each and every time before Ctrl-C, it was copying entire screens over in the left pane instead, site unseen. C-more has a focus issue, even the tag name tool tips intercept and steal mouse clicks.)
** I do have some event manager sounds working finally, but found that just because it is a .wav file does not mean C-more will play it. It has to be PCM format or at least not CCITT u-law. The simulator played those fine.