I was wondering...
Is it possible to disable the prompt on Mac OSX Lion that says.
Are you sure you want to run this script? [Yes, Cancel]
I added this script to the "Login Items" File to start automatically when I login, but the prompt still pops up. Any Ideas?
Thanks.
When an Applescript is saved as an application so that it can be run independently of Script Editor with a double-click, there is an option to have a "startup screen" which, in Snow Leopard and before (I don't have Lion), offers a choice between "Run" (the default) or "Quit". I imagine you might have enabled that feature without realizing, or maybe in Lion it is now activated by default.
Related
I'm using OSX's launchctrl functionality to automatically relaunch an app after it crashes.
Unfortunately, when the app relaunches, it launches together with an action window that reads:
"The last time you opened MyAppName, it unexpectedly quit while reopening windows. Do you want to try to reopen its windows again?"
I tried to suppress it by calling NSQuitAlwaysKeepWindows
defaults write -app /Path/to/app/MyAppName.app NSQuitAlwaysKeepsWindows -bool false
But this only works some of the time - I'd say that the popup window launches 50% of the time.
This window requires action and blocks the app from jumping into a full screen mode.
I'm on OSX 10.8.4
Thanks for any ideas ...
Jeremy
Open the folder "~/Library/Saved Application State" and look for a file like "some.url.MyAppName.savedState".
Deleting this file might probably solve the problem, at least it worked for me.
I was able to fix mine by deleting the Envelope Index file(All the files with the name "Envelope Index") under /Library/Mail/V2/MailData folder.
Then restart the mac.
I am working on a cocoa application. I see a strange behaviour on Mac OS 10.6.8..!
My Cocoa application has an Automator action inside it. I want it to be listed in Automator as soon as I install it.
The conditions are as follows:
1. After installation, user should not go to the installed path.
2. User should not launch the application.
I mean, I am seeing this bug only for above mentioned situations. If I go to the installed folder, or launch the application, the automator app gets listed.
I didn't see this defect on Mac OS 10.7.5 or Mac OS 10.8.2..
Also I tried touch command via terminal just in case thinking that if any kind of Access updating is required and all. But that wasn't the case.
Any suggestions? Can I run any kind or Shell/Applescript while installing [After installation of the application] so that I can list the automator action in automator?
Any advice or help would be great!!
You can have a .txt file with the below script and then you have to add postflight script when taking .pkg file in Package Maker.
open "/Applications/yourAppName.app"
Try this Terminal command.
/System/Library/Frameworks/CoreServices.framework/Frameworks/LaunchServices.framework/Support/lsregister .../Whatever.app
You shouldn't hard-code the path, though, as users sometimes stick apps in weird locations (citation: I do it :).
I am trying to install Xcode 4.1 GM on my Lion mac but it's not working. When it is almost finished, I get the popup to quit iTunes even though it is already quit. So the only option I have is to quit iTunes helper or alert in activity monitor, then it finishes the install. However then Xcode crashes on launch. Any ideas?
You can go into Activity Monitor and Quit the iTunes helper. That will also get Xcode to finish.
Looks like you've solved the install problem. It's not a solution per se, but setting Xcode to run in 32-bit mode fixed the crashing problem for me.
It's too early to say what the trade-off is (if any), but whatever it is, it's bound to be better than not being able to use it at all.
On a side note: please accept Phil's answer since he gave the correct solution to your original problem. C:
if you boot into single user mode (Press S when starting up), the installation works as it should. Xcode will then function without switching it to 32-bit mode.
Open "Activity Monitor" (press Command+Space to bring up spotlight, or find it in Applications.)
Sort by Process Name and find the process called "iTunesHelper".
From the "View" menu choose "Quit Process".
Then click on the "Force Quit" button. Xcode installation should continue now.
Try to use the xCode through the Finder after you get this problem. It happened to me, but I can still run the xCode.
I think it's something to do with your version of itunes is more updated than your Mac Os version.
I've got a Flash projector which I plan to distribute on CD. I'm making a projector for Mac and Windows. I know how to do Autorun on Windows, but I want to do so on Mac as well.
How does that work?
It doesn't. Mac OS 7–9 had a similar system but Mac OS X has nothing of the sort.
Your best bet is to make a nice Finder window design that makes it clear what to do. DropDMG may be useful.
There is no autorun in OSX anymore.
You can't set an application to autorun for security reasons. However you can set a Finder window to auto open on insert. I've seen a lot of CDs do this then have a "Click here to start" icon.
This is the terminal command to set it up on your diskimage before burning. discName should be the name of your disk image.
sudo bless -folder "/Volumes/discName" -openfolder "/Volumes/discName"
More info here
There is an easy way to do it. Just right-click the icon in the dock, chose "Options", then "Open at Login"
Then the selected app will launch every time OSX boots.
I wrote a simple Mac 'Service' for Finder, that executes a command.
Basically: this adds a ContextMenu in Finder.
If I right-click a file in Finder, a menu item pops up. If the user clicks it, it executes my script. (kind of like 'Send to Bluetooth device, ...')
In OS X Leopard (10.5) and earlier, all services are enabled.
In 10.6 (Snow Leopard), Apple changed the behavior, services now have preferences, and can be enabled or disabled by the user. (which is a good thing)
However, I wrote the service, but there seems to be no way to enable it automatically (in our installer).
I tried doing it with Applescript, going to the System Preferences and ticking the checkbox that way, but it requires some accessibility features to be turned on. (off by default).
Is it possible? If so, how?
Or do I need something else to provide Context Menus in Finder.
I tracked File changes on my filesystem while changing the preferences and discovered there was a plist file:
~/Library/Prefrences/pbs.plist
which contains what I need.
If I edit that manually, it seems to work. So, problem solved :)