Dan,
OK when referencing the xlateInxxx and xlateOutxxx remember they are lists and need to be treated as such.
So for at least the portion of your code that produces the xlateOutVals since you ar not treating it as a list it is looking like thes (the > and < ar mine):
>MM/DD/YYYY HH:MM:SS AM<
Note the spaces. Since the Xlate treats xlateOutVals as a list and white space (a space is white space) delimits ele4ments in the list you have provided a list with threee elements (date, time, AM/PM) and the Xlate will select the firs – hence you ar only getting the first element out of the Xlate.
If you were to use something like:
lreplace xlateOutVals 0 0 [clock format [clock scan $newDate] -f {%m/%d/%Y %l:%M:%S %p}]
Then you would give this back to the Xlate:
>{MM/DD/YYYY HH:MM:SS AM}<
Note the curly braces – now this is a single element list and should work fine (assuming none of your input has any white spaces).
To be sure you handle the xlateInVals properly do something like an lindex against it.
email: jim.kosloskey@jim-kosloskey.com 29+ years Cloverleaf, 59 years IT - old fart.