View Single Post
Old 12-05-2012, 03:51 AM   #96
sltyler1
Junior Member
 
Join Date: Dec 2012
Posts: 3
Default

Quote:
Originally Posted by chandler767 View Post
Applescript.

Code:
set the alert_message to "You may now plug in your DisplayLink device."
display dialog the alert_message buttons {"OK"} default button 1
set the my_choice1 to the button returned of the result
if my_choice1 is "OK" then
end if
on quit
	
	set the alert_message to "Unplug your DisplayLink device now."
	display dialog the alert_message buttons {"OK"} default button 1
	set the my_choice to the button returned of the result
	if my_choice is "OK" then
		tell application "Finder"
			continue quit
		end tell
		
	end if
	continue quit
end quit
thanks for that! will be doing some more testing/messing with the code this weekend to see if it's possible to integrate the script and the application.

did however get the application to hide and just run in the background except popping up and showing in the dock when the message is displayed.
sltyler1 is offline   Reply With Quote