Saturday, June 24, 2017

#1 2008-07-10 12:24:54 pm

Adam Bell
Administrator
From: Nova Scotia, Canada
Registered: 2005-10-04
Posts: 4658

TextEdit Script Wipes out your Desktop -- don't try this; read.

Applescript:

set P to path to desktop folder
tell application "TextEdit"
   set E to make new document at end of documents with properties {name:"Test Format", path:path to desktop folder}
   save E in P
end tell

I may be doing this improperly, but the net effect is pretty bad -- you get an error message with two buttons but no matter which of them you choose, your desktop contents disappear. Don't try this unless you have a recent time machine backup and administrator privileges to restore your desktop.

After you do restore it, "path to desktop folder" will fail until you log out and in again, or wait a minute or so during which it "heals".

EDIT: Standard Additions can no longer find the "path to desktop folder" though the Finder can. A restart is required to fix that. It doesn't heal. I've repeated this several times.


iMac running OS X 10.11.6

Filed under: TextEdit

Offline

 

#2 2008-07-10 05:31:25 pm

Adam Bell
Administrator
From: Nova Scotia, Canada
Registered: 2005-10-04
Posts: 4658

Re: TextEdit Script Wipes out your Desktop -- don't try this; read.

The bug is in the warning -- the buttons don't work properly. The rest is explained in this response to another thread by Nigel Garvey


iMac running OS X 10.11.6

Offline

 

Board footer

Powered by FluxBB

[ Generated in 0.033 seconds, 11 queries executed ]

RSS (new topics) RSS (active topics)