Kill process using Shell Script

Hi there

I am having difficulty with what should be a simple script.

When I run this:

tell application "System Events"
	-- find running apps
	set runningApp to name of every process
end tell

I get a list of processes which includes:

I am interested in killing “EPSON Scanner”

I thought this would so it:

do shell script "killall " & "EPSON Scanner"

But I get this error:

This script returns a true result:

return (do shell script "ps axc") contains "EPSON Scanner"

But this script returns a false result:

return (do shell script "ps axc") is equal to "EPSON Scanner"

Can anyone help? I am stumped.




do shell script "killall " & quoted form of "EPSON Scanner"

without the quotation the shell treats both words as separate parameters

Cheers, Stefan:)

Duh! I should not do this part time but it is fun!