mtimmsj wrote:It's behavior is inconsistent but you should be able to do this with:
Code: Select all
set theChat to make new chat with contacts {contact "123123321"} without new chat window
It pops up a window then tries to merge it with an existing window. It seems that sometimes it is successful with the merge and sometimes it is not.
hi mtimmsj
your right the behavior is inconsistent
with the code
Code: Select all
set myContact to "someone@hotmail.com" as string
tell account "me@hotmail.com" to set theChat to (make new chat with contacts {contact myContact})
send theChat message "hello"
the tab is created but the script falls over and the message never gets sent. plus the tabs behave screwy until you drag the new tab about, then the tabs behave themselves.
with the code
Code: Select all
set myContact to "myYahooFriend" as string
tell account "myYahooIdent" to set theChat to set theChat to (make new chat with contacts {contact myContact} without new chat window)
send theChat message "hello"
the message is sent but for me this actually opened a new second chat window
obviously using "with" instead of using without had the same effect.
with the code
Code: Select all
tell account "myYahooIdent" to set theChat to (make new chat with contacts {contact "myYahooFriend"} with new chat window) = false
the message is sent but for me this actually opened a new second chat window
icq was even stranger, for some reason my friend was added via my aim account not my icq account and no code worked properly.
i deleted the contact and re-added them under my icq account, this time i could create a new chat window but could not create a new tab for them.
aim seemed to behave the same way as yahoo and msn did.
maybe there isnt a way to do this! - yet
clive