Controlling iPhone volume from within application

Discussion in 'iOS Programming' started by lilmul123, Jul 3, 2009.

  1. lilmul123 macrumors newbie

    Joined:
    Jun 30, 2009
    #1
    Is this possible? I'd like to be able to control the iPod volume using a slider within my application instead of having to press a physical button to make it happen.
     
  2. lilmul123 thread starter macrumors newbie

    Joined:
    Jun 30, 2009
  3. simplymuzik3 macrumors 6502a

    Joined:
    Jan 29, 2009
    #3
    It is possible. You have to use AVFoundation.framework which lets you control play, pause, volume etc. Here's a good youtube video that's easy to follow.

    http://www.youtube.com/watch?v=uyEjidHn9cw

    Just follow the tutorial and then when you want to change the volume, make a slider in IB, then when you adjust the slider change the volume. ex:

    slider.value = volume;

    Also when you follow the video tutorial, make sure you dont "copy resources to group folder" when you add the framework. It causes problems when you do that in 3.0. Hope this helps you! :D
     

Share This Page