How do i start my sound?

All your problems with Audio, Video and Images.

How do i start my sound?

Postby who1 » Tue Jul 20, 2010 8:40 pm

I am using this code for my sound
Code: Select all
MediaPlayer mp = MediaPlayer.create(context, R.raw.bt); mp.start();
but on the Start() it says"Syntax error on token "start", Identifier expected after this token". Could some one give me an example of wahat to put after this or what to put after this?
thanks.
who1
Freshman
Freshman
 
Posts: 5
Joined: Tue Jul 20, 2010 4:27 am

Top

Re: How do i start my sound?

Postby blundell » Thu Jul 22, 2010 9:40 am

Syntax error usually means your missing a ; or something like that.

For a proper mediaPlayer implementation use the AndDev Search box
et voila: post49713.html?hilit=mediaplayer#p49713
User avatar
blundell
Master Developer
Master Developer
 
Posts: 1610
Joined: Tue Nov 18, 2008 12:58 pm
Location: UK

Top

Return to Multimedia Problems

Who is online

Users browsing this forum: No registered users and 18 guests