I discovered this as I joined a channel with a long name, and attempted to talk with my on input scripts which use /msg directly to output the final text. I have ascertained that the problem is mIRC's, not a script's.
It is this.. in /msg $1 $2-, $1 is chomped to 60 chars, even though for example EFnet's limit is 90 chars.
/join #i_am_here_because_my_client_is_misconfigured_to_auto_join_when_invited
/debug @moo
/!msg #i_am_here_because_my_client_is_misconfigured_to_auto_join_when_invited text
(the ! makes it use mIRC's inbuilt function over any scripted aliases, just to be certain)
Switch to the debug window, you will notice that a msg has been sent to #i_am_here_because_my_client_is_misconfigured_to_auto_join_w .. and you subsequently get a No such channel error (unless you are on a channel #i_am_here_because_my_client_is_misconfigured_to_auto_join_w also :P)
#i_am_here_because_my_client_is_misconfigured_to_auto_join_w is 60 characters long.
/msg shouldn't be chomping target name! I haven't been able to try this as nicks that long aren't possible but I can only imagine the function is hardcoded the same way for non-channel targets too.
Tomalak