SparkLabs Forum.

Community Help.


Applescript control broken in 1.7.6b1

this (below) used to work, now it doesn't? getting: "Viscosity got an error: AppleEvent handler failed."

Code: Select all

tell application "Viscosity"
   set connectionNames to connections
   set connectedName to ""
   
   repeat with theConnection in connections
      set theState to state of theConnection
      if theState is "connected" then set connectedName to name of theConnection
   end repeat
   
   return connectedName
end tell
Hi szymon_k,

Thanks for the bug report - much appreciated! I can confirm we're seeing the same behaviour (looks like it was an issue that was caused by the move from Swift 3 to Swift 4), and it should now be fixed in the latest beta version released today.

Also, you can shorten your script down to just the following :)

Code: Select all

tell application "Viscosity" to return name of first connection whose state is "connected"


Cheers,
James
2 posts Page 1 of 1

Copyright © 2016 SparkLabs Pty Ltd. All Rights Reserved. Privacy Policy