Page 1 of 1

Applescript question

Posted: Thu Sep 21, 2006 6:08 pm
by Livio
Hi,

I'm trying to connect Adium to Filemaker via Applescript ... this works, but not 100%. I have difficulties fetching the chat message content in Applescript. I looked everywhere on Google and this forum, but can't find any working examples. Who can help ?

This is what i have so far :

Code: Select all

tell application "Adium"
	activate
	tell the active chat of the first interface controller
		set chatternaam to chat name
		set chatid to ID
	end tell
	
	--set theText to the plainText message of first chat
	--display dialog theText
end tell


tell application "Adium"
	activate
	
	--if theText = "log" then
	if "a" = "a" then
		
		tell application "FileMaker Pro Advanced"
			activate
			go to database "adium"
			go to layout "adium"
			create new record
			set data field "wie" of last record to chatternaam
			set data field "wie_id" of last record to chatid
		end tell
		
 --send (active chat of the first interface controller) message "Filemaker Record added"

	end if
	
end tell


What's the correct applescript code for getting the message from the chat window ?

BTW ... i use version 1.0beta12

Livio

Posted: Fri Sep 22, 2006 6:40 am
by Catfish_Man
Does this work in b11? (it's worth checking, I did change something AS related)

Posted: Fri Sep 22, 2006 10:41 am
by Livio
Haven't tested it with Beta11 as I just started with B12. Where can I download Beta11 ?

http://adiumx.cachefly.net/Adium_1.0b11.dmg -> File not found :-)

Livio

Posted: Fri Sep 22, 2006 1:30 pm
by Catfish_Man

Posted: Fri Sep 22, 2006 8:18 pm
by Livio
I just tested it with B11 ... makes no difference... sorry :-)


Livio

Posted: Fri Sep 22, 2006 11:26 pm
by Catfish_Man
Excellent! That means I didn't break it. No idea how to fix it though, sorry. My AS knowledge is sadly lacking.

Posted: Sun Sep 24, 2006 11:51 pm
by Livio
Should this be posted as a bug ?

Livio