View Full Version : keep iTunes from asking for confirmation of Quit
bmongtangco
09-11-2008, 07:44 AM
hello,
i am developing a small iTunes application using the iTunes SDK on c#.
im finding a way to dispose the iTunes com object after use so that when the user exits the iTunes application, it will not ask a confirmation that a '3rd party software' is using iTunes.
help!
thanks!
hayne
09-11-2008, 08:36 AM
Your mention of COM objects makes me think that you are developing a Windows app.
This forum is for developers on OS X (as indicated in the name of the forum).
bmongtangco
09-11-2008, 08:40 AM
Your mention of COM objects makes me think that you are developing a Windows app.
This forum is for developers on OS X (as indicated in the name of the forum).
sorry bout that hayne,
im a bit desperate in finding a valid solution for this.
anyway, im sure some of you guys have used the iTunes sdk. is there a way to prevent the app from saying "One or more applications are using the iTunes scripting interface. Are you sure you want to quit?"
maybe disposing the iTunes object after use?
hayne
09-11-2008, 08:47 AM
The iTunes SDK on Mac does not use COM. I know that even though I haven't even looked at the SDK. It is likely that on Mac it is done via AppleScript.
In any case, on the Mac it is possible to script iTunes via AppleScript and the following short AppleScript quits iTunes without any confirmation needed:
tell application "iTunes" to quit
bmongtangco
09-11-2008, 08:57 AM
The iTunes SDK on Mac does not use COM. I know that even though I haven't even looked at the SDK. It is likely that on Mac it is done via AppleScript.
In any case, on the Mac it is possible to script iTunes via AppleScript and the following short AppleScript quits iTunes without any confirmation needed:
tell application "iTunes" to quit
thanks for extending your patience.
anyway, ive looked at the iTunes sdk library for the Quit() method. however, it doesn't seem to work.
big thanks again! if anyone has fresh ideas, i'd also like to hear them.
EatsWithFingers
09-11-2008, 06:19 PM
Take a look at this page (http://www.workingwith.me.uk/articles/java/itunes-com-with-java-and-swing). It deals with Java, but the idea seems to be for your external app to catch the event which corresponds to iTunes quitting, then release your com thread. In C#, it may be a message you have to catch (I've never used C# - only C).
I've also never used the iTunes SDK, let alone programmed on Windows, so I have no idea if this'll work, or even if it'll stop the dialog appearing...
bmongtangco
09-11-2008, 06:51 PM
Take a look at this page (http://www.workingwith.me.uk/articles/java/itunes-com-with-java-and-swing). It deals with Java, but the idea seems to be for your external app to catch the event which corresponds to iTunes quitting, then release your com thread. In C#, it may be a message you have to catch (I've never used C# - only C).
I've also never used the iTunes SDK, let alone programmed on Windows, so I have no idea if this'll work, or even if it'll stop the dialog appearing...
hello,
yes, ive seen this already. the iTunes.Quit() method does close the iTunes automatically.
We've managed to catch an event that we pass from our plugin to the c# app when iTunes close. But ofcourse, that will only trigger when iTunes is closed already.
Unless we could somehow catch the close event in the iTunes app before iTunes could even know it... other than that, it seems impossible to make this thing work.
vBulletin® v3.8.4, Copyright ©2000-2010, Jelsoft Enterprises Ltd.