Hello everyone,
I’ve just had a peak of curiosity for a second, and was wondering what was the equivalent of the beep command in ASOC? I know that the plain Applescript command works, I am looking for a more Cocoa equivalent.
I’ve only found this in the docs:
[b]kDefaultSysBeep[/b]
in one of the code examples, but nothing in the references or NSSound.
Challenge or no challenge?
Browser: Safari 531.22.7
Operating System: Mac OS X (10.6)
Found this, but I think it is C, not ObjC, therefore untouchable from ASOC:
[b]AlertSoundPlay[/b]
Browser: Safari 531.22.7
Operating System: Mac OS X (10.6)
The equivalent is NSBeep(), but that’s a C-style function call, not Objective-C, so you can’t call it from ASObjC. And really, there’s no reason not to use the standard AS beep.
That’s what I was afraid of. That was just for the fun of it. Thanks.
And just for my general knowledge, it is possible to wrap C in an objective c method, right?
Yep. Objective-C is a superset of C.