|
|
#1 |
|
AppleScript works but returns an error?
Okay the script is:
Code:
tell application "SkyDrive"
quit
end tell
set the_button to button returned of (display dialog "Did Skydrive close?" buttons {"Yes", "No"} default button 1)
if the_button is "Yes" then tell application "Terminal"
activate
do script "cp -av /Users/osx/Desktop/test /Users/osx/Desktop/untitled folder"
end tell
if the_button is "No" then display dialog "Please Try Again"
delay 2
set button_two to button returned of (display dialog "Was the copy successful?" buttons {"Yes", "No"} default button 1)
if button_two is "Yes" then tell application "SkyDrive"
activate
end tell
if button_two is "No" then display dialog "Please Try Again"
the error is: error "SkyDrive got an error: AppleEvent timed out." number -1712 Any help would be greatly appreciated!
__________________
Mac Mini 2011; Dell XPS L502x Nexus 7; iPhone 5 iPod Classic Last edited by TheMTtakeover; Jan 17, 2013 at 08:31 PM. |
|
|
|
0
|
|
|
#2 | |
|
Quote:
__________________
iMac Intel (Rev H, 27"), 1TB HDD, 16GB RAM, Ubuntu |
||
|
|
0
|
|
|
#3 | |
|
Quote:
Code:
if button_two is "Yes" then with timeout of 10 seconds tell application "SkyDrive" activate end tell end timeout
__________________
Mac Mini 2011; Dell XPS L502x Nexus 7; iPhone 5 iPod Classic |
||
|
|
0
|
|
|
#4 |
|
If anybody comes across this having the same problem the only workaround I was able to find was running it through the terminal so it would end up being
Code:
tell application "SkyDrive"
quit
end tell
set button_one to button returned of (display dialog "Did Skydrive close?" buttons {"Yes", "No"} default button 1)
if button_one is "Yes" then tell application "Terminal"
activate
do script "cp -av /Users/osx/SkyDrive /Volumes/Skydrive/$(date +%Y-%m-%d)"
end tell
if button_one is "No" then error number -128
set button_two to button returned of (display dialog "Was the copy successful?" buttons {"Yes", "No"} default button 1)
if button_two is "Yes" then tell application "Terminal"
do script "open -a SkyDrive"
end tell
if button_two is "No" then error number -128
__________________
Mac Mini 2011; Dell XPS L502x Nexus 7; iPhone 5 iPod Classic |
|
|
|
0
|
![]() |
|
«
Previous Thread
|
Next Thread
»
| Thread Tools | Search this Thread |
| Display Modes | |
|
|
All times are GMT -5. The time now is 10:38 PM.







Linear Mode
