Warning: file_get_contents(/data/phpspider/zhask/data//catemap/3/android/216.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
android媒体不工作_Android - Fatal编程技术网

android媒体不工作

android媒体不工作,android,Android,我在res文件夹中创建了一个raw文件夹,并且我过去了一首mp3歌曲,但在eclipse中显示错误R.raw无法解决,并且在控制台中显示了无效的文件名:必须仅包含[a-z0-9] 我的mp3文件名是MaidwiththeFlaxenHair.mp3,在构建项目之后,同样的文件名也会出现 这就是代码 MediaPlayer player = MediaPlayer.create(this, R.raw.MaidwiththeFlaxenHair); player.start(); 仅使用小写字母

我在res文件夹中创建了一个raw文件夹,并且我过去了一首mp3歌曲,但在eclipse中显示错误R.raw无法解决,并且在控制台中显示了无效的文件名:必须仅包含[a-z0-9] 我的mp3文件名是MaidwiththeFlaxenHair.mp3,在构建项目之后,同样的文件名也会出现

这就是代码

MediaPlayer player = MediaPlayer.create(this, R.raw.MaidwiththeFlaxenHair);
player.start();

仅使用小写字母:
maidwiththeflexenhair.mp3
->
maidwiththeflexenhair.mp3