Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

GRMrGecko

macrumors member
Original poster
Hello, I'm trying to change the status message of Adium using the Scripting Brige and am having no luck.

It always crashes and has this message
Code:
2009-07-03 18:46:03.437 Adium Status[25959:10b] An uncaught exception was raised
2009-07-03 18:46:03.440 Adium Status[25959:10b] *** -[SBProxyByClass setTitle:]: object has not been added to a container yet; selector not recognized [self = 0x1eaaa0]
2009-07-03 18:46:03.441 Adium Status[25959:10b] *** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: '*** -[SBProxyByClass setTitle:]: object has not been added to a container yet; selector not recognized [self = 0x1eaaa0]'

My code is.
Code:
AdiumApplication *adium = [[SBApplication applicationWithBundleIdentifier:@"com.adiumX.adiumX"] retain];
AdiumStatus *status = [[[[adium classForScriptingClass:@"status"] alloc] init] autorelease];
[status setTitle:@"Some Title"];
[status setStatusType:AdiumStatusTypesAvailable];
[status setSaved:NO];
[adium setGlobalStatus:status];

Thanks for any tips,
Mr. Gecko
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.