on 01-28-2010 8:09 PM
Does anybody know if we could play sounds or beeps on the handheld device using WebDynpro for Java (NW7.01)? We have a client requirement to have the handheld device beeps/makes different kind of sounds after the goods receipt is posted. We are looking for a way to play the sounds thatu2019s saved on the deviceu2019s directory. Appreciate any suggestions or input.
Thank you!
Teeracha
Hi,
well, WD handles events and is Java, so in the Event handling place:
AudioPlayer test = new AudioPlayer("YOUFILENAME");
test.play();
and it will play the sound. It works fine for me, so it should work fine for you. As well it workson PDA, cause Creme knows AudioPlayer as well.
Hope this helps.
Regards,
Oliver
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Oliver,
Thank you very much for your response. Our developer was using the same class, but he said it was not able to read the sound device on server and was resulting in dump. The response might be considering a case when WebDynpro is running on same system as of webAs java server. Do you have any suggestion on this? The device we're using is MC9090 with Windows Mobile 5.0.
Thanks again,
Teera
Hi,
playing sounds is at least not officially supported by Mobile Web Dynpro, so I don't think that it will work out of the box.
What you could try, depending on your NetWeaver Version is to use JavaScript to play sounds. Please keep in mind that the insertion of JavaScript into Mobile Web Dynpro is not officially supported by SAP, but it works at least for the version SAP NetWeaver 7.0.
Best Regards,
Stefan
Hi,
I find it strange that you see this error message - due to the fact, that you try to use a Creme method. Have you tried to run the MP3 Player delivered by Creme or even to simply use Creme without MI to play a sound? I would suggest the issue is more a wrong path or filename - can be a format issue as well. But in princiopal: you want to run it in pure Java Code, the WD-Client just gives you the event to do that - so it should be possible?!?
I have used it several times with all other clients (JSP, AWT) and it works fine for us.
Regards,
Oliver
Hi,
my understanding was that you are using Mobile - Always Connected, with a browser based solution and no installation on the client at all. If this is not true and If you are using Mobile for Occsionally Connected clients with an installed instance on the device, I agree with Oliver and it should work.
Best Regards,
Stefan
Hi Teera,
sorry, I thought you are using the Client version on the device - While using always online, playing sound is not supported by WebDynpro on the device. You can try JavaScript coding as mentioned by Stefan earlier, but this will only work 100% in your environment. If you switch browser you run into the typical issues. But at least it is worth to try it.
Hope that helps.
Regards,
Oliver
Hi Former Member,
Playing sound/beep on the handheld device using WebDynpro Java (7.1) i saw the Above discussions thats was help ful to me, and i am new to this Java web dynpro, i need more clarifications in above discussion.
Thanks & Regards,
Naveen kumar.
i am waiting for your reply
Playing sound/beep on the handheld device using WebDynpro for Java (NW7.01)Playing sound/beep on the handheld device using WebDynpro for Java (NW7.01)
Hi Terracha,
you can use bellow mentioned methods for playing a sound using javascript :
function playSound( url ){
document.getElementById("sound").innerHTML="<embed src='"+url+"' hidden=true autostart=true loop=false>";
}
or
https://github.com/admsev/jquery-play-sound
$.playSound('http://example.org/sound.mp3');
Hope that helps you as a workaround way.
Regards,
Srinivas Divakarla
Thanks for your reply,
Still i need more clarifications about where to place the sound file, Shall we keep it in mime Folder or in mobile device ?
User | Count |
---|---|
85 | |
10 | |
10 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.