Can not play audio from speaker - Help!

I want to play a simple sound through the speaker and we have tried the following code:

player = Manager.createPlayer(Manager.TONE_DEVICE_LOCATOR);
player.realize();
ToneControl tc = (ToneControl) player.getControl("ToneControl");
tc.setSequence(aSeq);
VolumeControl vc = (VolumeControl) player.getControl("VolumeControl");
vc.setLevel(100);
AudioPathControl apc = (AudioPathControl) player.getControl("AudioPathControl");
//apc is now null and therefore the below throws an exception
apc.setAudioPath(AudioPathControl.AUDIO_PATH_HANDSFREE);
player.start();

Since I don't seem able to get the AudioPathControl object, could someone tell me what is the problem with the above code and how do I do instead?

Thank you!!

Have you checked these KB articles.

How - audio Play in an application

http://www.BlackBerry.com/knowledgecenterpublic/livelink.exe/fetch/2000/348583/800332/1089414/How_To...

How - to specify routing Audio Path

http://www.BlackBerry.com/knowledgecenterpublic/livelink.exe/fetch/2000/348583/800332/1089414/How_To...

Concerning

Bika

Tags: BlackBerry Developers

Similar Questions

  • Equium A100-147: can not play videos from the site with WMP

    When I try to play videos from a Web site, I get an error message. "Windows Media Player received. Error message Windows Media Player cannot access the file. The file may be in use, you won't have access to the computer on which the file is stored, or your proxy settings are may not be incorrect. »
    ERROR CODE DOOD11D2

    My computer settings are set out at the time of purchase. Is this normal?

    Hello

    I think the error messages says that everything you need to know:
    You can not read the file because:

    -Is the file may be in use
    -you won't have access to the computer where the file is stored
    -your proxy settings are may not be not correct

    The proxy settings must be defined on use web browser proxy settings, you can find the setting when you open the WMP and tab marks the Protocol HTTP and meadows configure network.

  • iPhone 7 will not play audio via the USB port on the car.

    When I plug my iPhone USB port 7 more in my car (15 Jeep Grand Cherokee), the artist/song/podcast information appears on the screen, but the sound plays through the speakers of the phone.  I have confirmed that my settings are all the same as they were on my 6s, who played without any problems via the USB connection.  Bluetooth streaming works fine - no problems at all.  Any ideas, or is this a problem similar to that people have with CarPlay?

    Welcome to Apple Support communities, kevo.mac!

    Congratulations on your new iPhone 7 more! I see that you connect with your Jeep Grand Cherokee using the USB port. Everything seems to work fine, except that the music plays through the phone instead. I'll be happy to help you to get this working.

    Help to connect your iPhone, iPad or iPod touch with your car radio

    If you are using USB playback

    Restart your iOS device and your car.
    Connect your iOS device to another stereo USB port (if you have one).
    Try another USB cable.
    Update your iOS device.
    Install the updates to the firmware of your car radio.
    Test of audio playback from a different application. If you can not play audio from a specific third party application, contact the developer of the app for help.
    If you can not play audio from an app Apple, contact Apple technical support.

    Enjoy your weekend!

  • Apparently, the surface has Flash Player but can not play on a site. Help, please!

    Apparently, my Surface installed Flash Player, but my daughter can not play on a site called Friv, which requires Flash player. I have no idea why this might be. apparently you can play friv by changing the compatibility in the tools, but I can't!  All ideas

    Hi Lisa,

    Flash Player is integrated with Internet Explorer in the Windows 8 operating system. As he fails to open certain Web site, refer to the suggestions from the following link and check to see if they help.

    Flash Player help / Flash Player issues. Windows 8

    http://helpx.Adobe.com/Flash-Player/KB/Flash-Player-issues-Windows-8.html

    Hope that the information provided is useful. If you have additional questions, or if this problem persists, come in and we will be happy to help you.

  • I need help I can not play second life be cuse is my ethier video card driver is not properly installed or is outdated

    Please help in need a download that I play on my acount of life secoend and I can not play and Games downloaded ethier please help

    try to visit the computers and see if they are all available to download and install the updated drivers.

    you will need to enter the model number of your computer to its place of origin in order to know what is available.

  • I can't hear any sound when you play a HDMI video uploaded to youtube, plays very well while on youtube but will not play sound from my hard drive after the use of realplayer download

    I can't hear any sound when you play a HDMI video uploaded to youtube, plays very well while on youtube but will not play sound from my hard drive after using the lplayer rea download

    Hello

    We will try to download different video using different downloader (other than RealPlayer) and see if the problem still persists.

  • I can't play videos from a simple site like CNN - HELP / Windows 8

    Hello

    Some settings have been changed on my computer.  I don't know what I did.  I upgraded to 8.1 to see if it would fix the

    problem of not being able to play simple video on cnn.

    Whenever I try to read the CNN video, it says: "cannot display the content checking internet connection.

    It is not a problem with internet connection, otherwise I would not yet be able to get on CNN.

    Why I can't play video?

    Help, please.

    Do I need Adobe? Flash?  I have no idea what happened.

    Thank you

    -j

    I would try first just reset your Internet Explorer, it can probably solve the problem.  Here's how:

    How to reset Internet Explorer
    http://support.Microsoft.com/kb/923737

    Since you are using Windows 8.1, you will need to use the "manual" section of these instructions.

  • I need help on how to audio output when I go. I ticked the box at the bottom, but when I go to view my video on quicktime, it does not play audio.

    I need help on how to audio output when I go. I ticked the box at the bottom, but when I go to view my video on quicktime, it does not play audio.

    GUYS, I GOT IT. AND THE SOLUTION IS WAYYYYY WITH JUST A RENDERING. So after countless time I spent trying to make it, I found a way that me really happy that my old rendering has not worked. All you have to do is download adobe media encoder and BAM your gold. I make it in h.264 that i couldt using the old rendering and now it works fine.

  • HTML5 content published from Captivate 7 including audio slide do not play audio in the DPS overview

    I added 5 HTML contained in a publication of DPS that I created in Indesign CC. When I saw the content on my desktop I do not play audio when the Insider. The content, but without audio. is this normal? I cannot publish to a device right now and am just trying to figure out if I'm doing something wrong.

    There is no substitute for testing on a device.

  • Satellite A300D - is overheating and can not play games

    Hello
    I'm quite desperate. My Satellite A300D is overheating. I can not play new games. Temperature hit 94 degrees and laptop is restarted. I cleaned it several times, very precisely and nothing. So I decided to send it to the official service of Toshiba. After that, the phone is still the same.

    My only hope is buy cooling grease and cooling stock-base. But before that ideas, advice?

    Thanks for everything...

    Hello

    I can understand you mate, but have you contacted Toshiba service center again? You should speak with the technicians and explain the situation. I put t know what they did, do you know that?

    Cleaning of the laptop is still a good idea but if it doesn't work maybe the thermal compound must be renewed. So ask a technician for help laptop.

    By the way: what OS are you using? You can use the same problem with the factory settings and preinstalled display driver?

  • Windows 7 does not play Audio or Audio files into video files

    I recently had trouble with my permissions of file being messed up because of a bad Windows Update and after to find most of my problems and access to almost everything I find I can't play audio files such as mp3 or wav in any player (Winamp, iTunes, etc.) or have game audio while watching a video file (I tried VLC).

    The strange thing is that audio plays very well while doing something in my web browser, Google Chrome, and I can even open the mp3s in Chrome and have them play. When I try to open an audio file in Windows Media Player, I get an error C00D11B1, else hangs the program or does not play at all, the timer remains at 0. I tried to recharge my programs, codecs and drivers, but to no avail. System Restore is not an option I lost somehow those I had over the screw up that changed my permissions.

    Any help or ideas would be very appreciated.

    Solved here...

    Windows Media Player C00D11B1 - Microsoft Community error code
    http://answers.Microsoft.com/en-us/Windows/Forum/Windows_7-pictures/Windows-Media-Player-error-code-C00D11B1/4a80bfc9-c849-49ff-8AF3-96efcf0867af

    And if it does not help, Vivian Xing [MSFT] another method.

    Windows Media Player 12 error C00D11B1 problem
    http://social.technet.Microsoft.com/forums/Windows/en-us/e3fc642b-d4db-4DEB-bba3-dc239ae684c0/Windows-Media-Player-12-error-C00D11B1-problem?Forum=w7itpromedia

  • A videoagrapher sent me to edit MOV files. When I try to read up on the timeline just stuck... can not play at all. any idea?...

    A videoagrapher sent me to edit MOV files. When I try to read up on the timeline just stuck... can not play at all. any idea?...

    Hi Gilad,

    It seems more an audio problem for me.

    Please select all the clips on the timeline, right-click and select 'Remove' to separate the audio from the videos.

    Once done select Audio only in the timeline and right click to select "Render and replace. Once done, save and close the project.

    Try reading to check if it works.

    You can also try to export an XML file i.e tab of project selection.

    Go to file > export > Final Cut Pro XML

    After creating a new project > import the XML file, and then open the sequence to check.

    Vinay

  • Once I downloaded the new version of Adobe Flash Player 11.3.300.262, I can not play games with my friends on Yahoo Messenger.

    It could be a coincidence, but when I upgraded to the latest version of Adobe Flash Player 11.3.300.262 I can not play games with my friends on Yahoo Messenger. I know that when I've updated for a reason that I had to try 3 times before it took. It shows that it is updated. I wonder if I have to uninstall and reinstall. Also, I never use Internet Explorer 8 but when I went there to check I found a plug check link there and it showed over there that Adobe Flash Player necessary update but it was an older version and not a Foxfire had updated me too. Now I'm really confused if it causes a problem. I've never had to control Internet Explorer for plug-ins before. Have always just updated to Foxfire since that's what I use. Adobe Flash Player seems to play videos OK not really sure if this is the issue or not. My Java plug-ins have been very well and have been updated some time there, so I know it's not that. Any help is appreciated. Thank you!

    Hey again,
    After hours of reading and checking to make sure I had good things enabled, I did, I gave up and uninstalled the latest version of Adobe Flash Player, they gave me and re-installed and later I had my friend get on Messenger and we tried games and it worked this time.
    For some strange reason when I updated it took me 3 tries before it took. So even if he told me that it has been installed, apparently it wasn't really. Just goes to show you that you can not trust what you see.
    What has really scratching my head was I went to Internet Explorer 8, which I never use more and discovered you can now get Mozilla plug in slip out there and when I did showed that same Adobe Flash Player is outdated but it was to a different version. Not knowing if it would help, I installed a new too and he said it was his understanding that it does not. So I guess you can have 1 version installed on the computer 1 despite 2 browsers different different versions. It becomes too complicated for me. Laughing out loud!
    I work with computers all the time at work but not the technical stuff. If it's something simple, I can guess through it to help someone but it's my first personal computer for me and is a former first, so I got experience using different types. We use the desk at work as well. Personally, I like computers laptops for various reasons. And the mention of people many browsers go way over my head.
    Please answer this question though and you answer back.
    DFelice

  • can I play music from my iPhone through my B

    Can I play music from my iPhone 6 to 2 B & O speakers without any other hardware?

    depend on the speakers that the output of the minijack connector is not quite high that speakers unamped unpowered full-size to play loud enough

  • Can not play in DOTA on Satellite L510 (i3) with Intel HD graphics card

    Hello

    Can anyone help me regarding the Satellite L510 (core i3)? Can not play in DOTA even if updated the latest display driver (Intel HD Graphics (Core i3) with 8.15.10.2086 version of the driver.) on Intel website, but still can not solve my problem. I tried to reinstall using win7 or vista OS but still the same.
    Someone at - he had to face the same problem with me?

    Thank you.

    Hello

    What s wrong exactly?
    You are not able to start the game?

    You compared the required for the game with the hardware specifications of notebooks?
    Your good enough to play this game material uses better resolution?

Maybe you are looking for