+ Reply
Results 1 to 3 of 3

Your favorite Apple, iPhone, iPad, iOS, Jailbreak, and Cydia site.


Thread: Having a button play a sound.

is a discussion within the

iPhone / iPod Touch SDK | Development Discussion

forums, a part of the

3rd Party Apps For iPhone | iPod Touch

section;
Hello. I would really appreciate help with this as it is boggling my mind for almost a week now. Ok, so, I am trying to have this button play a
...
  1. #1
    What's Jailbreak? sweeneytodd's Avatar
    Join Date
    Jun 2008
    Posts
    28
    Thanks
    1
    Thanked 2 Times in 2 Posts

    Default Having a button play a sound.
    Hello.

    I would really appreciate help with this as it is boggling my mind for almost a week now.

    Ok, so, I am trying to have this button play a sound when clicked. I just have no idea how to do this.

    I mean I know basics and stuff.

    In Interface Builder:
    Pretty much, what I have set up is Button connected to an object called sounds. Then, the event chosen is called "playsound1".


    I wrote the class files, put them in the classes folder. and now I'm staring at the sounds.h and sounds.m in Xcode, with no idea what to do.

    I was able to create a simple "Beep app" for REGULAR Cocoa using NSBeep. I just don't know how I can create an app that has this button that plays a given sound file in the app's filesystem.

    As always, thanks so much for all the help!
    iPhone 3G 16GB - Black.

    Screw the crAppStore I want Installer!

  2. #2
    lol that would be a cool app especially if you could change the sounds. I used to have a sound on my treo that sounded like a guy at works GPS so I would keep hitting it and it would drive him nuts! he even took it in for repair!! lmao!!

    Check out ifart and igiggle they do something similar to what you want I think

  3. #3
    What's Jailbreak? sweeneytodd's Avatar
    Join Date
    Jun 2008
    Posts
    28
    Thanks
    1
    Thanked 2 Times in 2 Posts

    they kind of do... but I can't get the source code... and.. they're jailbreak apps, so they are of no aid to me, unfortunately.

    bump?

    I found this:

    AudioServicesCreateSystemSoundID

    on the dev site.

    any ideas?
    Last edited by sweeneytodd; 07-13-2008 at 02:45 PM. Reason: Automerged Doublepost
    iPhone 3G 16GB - Black.

    Screw the crAppStore I want Installer!

Posting Permissions
  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts