Clovertech
› Clovertech Forums › Read Only Archives › Cloverleaf › Cloverleaf › Copy new messge over old
I am trying to copy a new message i created over the original message and return the new message to the engine. Here is my code any thoughts?
set newMh [msgcopy $mh]
msgset $newMh $new_ORM_Msg
echo $new_ORM_Msg
set dispList
and of course at the end of the proc.
return $dispList
A couple thoughts:
1. just use the existing message object to hold your new content
msgset $mh $new_ORM_Msg echo $new_ORM_Msg lappend dispList “CONTINUE $mh”
2. create a new message object, return that, and kill the old:
set newMh [msgcopy $mh] msgset $newMh $new_ORM_Msg echo $new_ORM_Msg lappend dispList “CONTINUE $newMh” lappend dispList “KILL $mh”
#1 is probably faster.
Rob Abbott Cloverleaf Emeritus
thanks a bunch