Thank you friends,
I suggest it's bug in Eclips because when I add resource in raw folder
didn't add any item and update R file.

On Mon, May 9, 2011 at 2:34 PM, harsh chandel <harshdchan...@gmail.com>wrote:

> no need to add it in manifest
> simply create an mediaplayer
>
> this will be the command:
>        int i=getResources().getIdentifier(s,"raw",getPackageName());
>        if(i!=0){
>                        MediaPlayer player = new
> MediaPlayer().create(getBaseContext(),i);;
>                        player.setVolume(0.9f, 0.9f);
>                        player.start();
>                        }
>
> s=name of the file
> raw is folder
>
> On May 7, 7:58 pm, Meba <mehdi.bahr...@gmail.com> wrote:
> > Hi,
> > I want to use a MP3 file as resource and copy this to res/raw and I
> > can access in activity by R.raw.MP3_FILENAME but when start this
> > application can't find this resource.(I'm try define it as meta-data
> > but I don't know how can I define this name)
> > how can I add mp3 file name in manifest and access to this.
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en
>

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to