Great...the script works...

Thank Huhu_Manix and vikke...I solve the problem in this way,naturally with your help...
code:
function send_emoticon(wnd)
{
if(wnd.EditChangeAllowed==true)
{
Emoticons = Messenger.CustomEmoticons;
e = new Enumerator(Emoticons);
the_wnd = wnd; // copia l'oggetto finestra
OnEvent_Timer("timer_name"); // lancia il ciclo
}
}
function OnEvent_Timer(timer)
{
if(timer == "timer_name")
{
var smile="";
for(var i = 0; !e.atEnd()&&i<5; e.moveNext(), i++)smile=smile+" "+e.item().Shortcut;
the_wnd.SendMessage(smile); // invia 5 smilies per volta
Debug.Trace(smile);
if(!e.atEnd())MsgPlus.AddTimer("timer_name", 4000); // chiama nuovamente l'evento Timer
}
}
I highlighted your only forgetfulness...
I hope to learn more in this forum...